This repository contains comprehensive samples and examples for WSO2 API Manager, covering various use cases from basic configurations to advanced AI-powered guardrails and deployment patterns.
Add custom analytics data to the existing event schema in WSO2 API Manager. This sample allows you to extend the default analytics events with custom attributes and data points.
Key Features:
Sample implementation for writing analytics event details to logs. Provides a custom reporter for API-M 4.0.0 that logs detailed analytics information.
Key Features:
Extracts and populates necessary attributes of API Analytics events from WSO2 APIM 4.2.0 for Thrift-based analytics publishing.
Key Features:
Publishes API Analytics events to Thrift streams including request, fault, and throttle events with comprehensive attribute mapping.
Key Features:
Entitlement handler implementation for role-based access control using XACML policies. Enables fine-grained authorization based on user roles and attributes.
Key Features:
Documentation:
Custom JWT token generator for passing end-user attributes to backend services. Allows you to include custom claims and user information in JWT tokens.
Key Features:
Documentation:
Gateway-specific JWT token generator for API-M 3.1.0, providing enhanced JWT generation capabilities at the gateway level.
Key Features:
JWT claim transformation component for API-M 3.1.0, allowing you to modify and transform JWT claims according to your requirements.
Key Features:
AWS Lambda function implementation for API Gateway authorization using JWT tokens. Validates JWT tokens and returns allow/deny policies.
Key Features:
This comprehensive guide covers the configuration, deployment, and usage of all available AI guardrails for WSO2 API Manager Universal Gateway. These guardrails provide essential protection, validation, and enhancement capabilities for AI APIs.
Star Wars example GraphQL server using Apollo Server and GraphQL Tools. Demonstrates GraphQL API implementation with a comprehensive schema.
Key Features:
Collection of backend services for streaming APIs including Server-Sent Events (SSE) and WebSocket implementations.
Server-Sent Events backend implementation for real-time data streaming with configurable timing and intervals.
Key Features:
WebSocket chat room server demonstrating real-time bidirectional communication capabilities.
Key Features:
Comprehensive Kubernetes deployment guide for WSO2 API Manager with automation scripts and best practices.
Key Features:
Components:
CI/CD pipeline implementations for WSO2 Micro Integrator with both VM-based and Kubernetes-based deployment strategies.
Key Features:
Kubernetes-based CI/CD pipeline for WSO2 Streaming Integrator with automated deployment and scaling capabilities.
Key Features:
Command-line tool for validating APIs against configurable rules and generating compliance reports. Ensures adherence to organizational standards and best practices.
Key Features:
Rule Categories:
Complete tutorial resources for WSO2 API Manager 4.1.0 with Docker Compose setup and sample backend services.
Key Features:
Components:
Sample backend services and resources for API Manager certification scenarios and testing.
Key Features:
Tutorial for deploying WSO2 API Manager with a single control plane and multiple gateways for distributed API management.
Key Features:
Complete collection of backend services for streaming API implementations including real-time data streaming and WebSocket communications.
Available Implementations:
Clone the repository:
git clone https://github.com/wso2/samples-apim.git
cd samples-apim
Choose a sample from the categories above
Follow the specific README instructions in each sample directory
Build and deploy according to the sample requirements
We welcome contributions! Please see our Contributing Guidelines for details on how to submit pull requests and report issues.
This project is licensed under the Apache License 2.0. See the LICENSE file for details.
| Category | Samples | Description |
|---|---|---|
| Analytics | 4 samples | Custom data providers, event publishers, and Thrift analytics |
| Security | 5 samples | XACML handlers, JWT generators/transformers, Lambda authorizers |
| AI/ML | 1 comprehensive demo | AI guardrails, content safety, PII protection |
| Backends | 3 samples | GraphQL, SSE, and WebSocket implementations |
| DevOps | 3 samples | Kubernetes deployment, CI/CD pipelines |
| Governance | 1 tool | CLI tool for API validation and compliance |
| Tutorials | 3 comprehensive guides | Complete tutorials with Docker setups |
| Streaming | 2 implementations | Real-time data streaming solutions |
For detailed information about each sample, please refer to the individual README files in each directory.
(top 30 of 35)
Java
24.9%
Python
24.6%
Ballerina
23.0%
Shell
14.4%
JavaScript
7.4%
Dockerfile
4.0%
Groovy
1.6%
This repository contains comprehensive samples and examples for WSO2 API Manager, covering various use cases from basic configurations to advanced AI-powered guardrails and deployment patterns.
Add custom analytics data to the existing event schema in WSO2 API Manager. This sample allows you to extend the default analytics events with custom attributes and data points.
Key Features:
Sample implementation for writing analytics event details to logs. Provides a custom reporter for API-M 4.0.0 that logs detailed analytics information.
Key Features:
Extracts and populates necessary attributes of API Analytics events from WSO2 APIM 4.2.0 for Thrift-based analytics publishing.
Key Features:
Publishes API Analytics events to Thrift streams including request, fault, and throttle events with comprehensive attribute mapping.
Key Features:
Entitlement handler implementation for role-based access control using XACML policies. Enables fine-grained authorization based on user roles and attributes.
Key Features:
Documentation:
Custom JWT token generator for passing end-user attributes to backend services. Allows you to include custom claims and user information in JWT tokens.
Key Features:
Documentation:
Gateway-specific JWT token generator for API-M 3.1.0, providing enhanced JWT generation capabilities at the gateway level.
Key Features:
JWT claim transformation component for API-M 3.1.0, allowing you to modify and transform JWT claims according to your requirements.
Key Features:
AWS Lambda function implementation for API Gateway authorization using JWT tokens. Validates JWT tokens and returns allow/deny policies.
Key Features:
This comprehensive guide covers the configuration, deployment, and usage of all available AI guardrails for WSO2 API Manager Universal Gateway. These guardrails provide essential protection, validation, and enhancement capabilities for AI APIs.
Star Wars example GraphQL server using Apollo Server and GraphQL Tools. Demonstrates GraphQL API implementation with a comprehensive schema.
Key Features:
Collection of backend services for streaming APIs including Server-Sent Events (SSE) and WebSocket implementations.
Server-Sent Events backend implementation for real-time data streaming with configurable timing and intervals.
Key Features:
WebSocket chat room server demonstrating real-time bidirectional communication capabilities.
Key Features:
Comprehensive Kubernetes deployment guide for WSO2 API Manager with automation scripts and best practices.
Key Features:
Components:
CI/CD pipeline implementations for WSO2 Micro Integrator with both VM-based and Kubernetes-based deployment strategies.
Key Features:
Kubernetes-based CI/CD pipeline for WSO2 Streaming Integrator with automated deployment and scaling capabilities.
Key Features:
Command-line tool for validating APIs against configurable rules and generating compliance reports. Ensures adherence to organizational standards and best practices.
Key Features:
Rule Categories:
Complete tutorial resources for WSO2 API Manager 4.1.0 with Docker Compose setup and sample backend services.
Key Features:
Components:
Sample backend services and resources for API Manager certification scenarios and testing.
Key Features:
Tutorial for deploying WSO2 API Manager with a single control plane and multiple gateways for distributed API management.
Key Features:
Complete collection of backend services for streaming API implementations including real-time data streaming and WebSocket communications.
Available Implementations:
Clone the repository:
git clone https://github.com/wso2/samples-apim.git
cd samples-apim
Choose a sample from the categories above
Follow the specific README instructions in each sample directory
Build and deploy according to the sample requirements
We welcome contributions! Please see our Contributing Guidelines for details on how to submit pull requests and report issues.
This project is licensed under the Apache License 2.0. See the LICENSE file for details.
| Category | Samples | Description |
|---|---|---|
| Analytics | 4 samples | Custom data providers, event publishers, and Thrift analytics |
| Security | 5 samples | XACML handlers, JWT generators/transformers, Lambda authorizers |
| AI/ML | 1 comprehensive demo | AI guardrails, content safety, PII protection |
| Backends | 3 samples | GraphQL, SSE, and WebSocket implementations |
| DevOps | 3 samples | Kubernetes deployment, CI/CD pipelines |
| Governance | 1 tool | CLI tool for API validation and compliance |
| Tutorials | 3 comprehensive guides | Complete tutorials with Docker setups |
| Streaming | 2 implementations | Real-time data streaming solutions |
For detailed information about each sample, please refer to the individual README files in each directory.
(top 30 of 35)
Java
24.9%
Python
24.6%
Ballerina
23.0%
Shell
14.4%
JavaScript
7.4%
Dockerfile
4.0%
Groovy
1.6%