diff --git a/docs-python/features/agent-modules/agent-gateway.mdx b/docs-python/features/agent-modules/agent-gateway.mdx new file mode 100644 index 00000000000..d42cfe59ed9 --- /dev/null +++ b/docs-python/features/agent-modules/agent-gateway.mdx @@ -0,0 +1,48 @@ +--- +id: agent-gateway +title: Agent Gateway Service +hide_title: false +hide_table_of_contents: false +sidebar_label: Agent Gateway Service +description: Discover MCP tools and A2A agents from connected SAP LoB systems via the Agent Gateway Service +keywords: + - sap + - cloud + - sdk + - python + - agent gateway + - mcp + - a2a + - langchain +--- + +The Agent Gateway Service (AGW) is the central communication hub for SAP BTP agents. +It supports two integration protocols: **MCP** for discovering and calling tools exposed by connected SAP LoB systems such as SAP S/4HANA and SAP SuccessFactors, and **A2A** (Agent-to-Agent) for discovering remote agents and delegating tasks to them. + +### LangChain Integration + +Convert MCP tools to LangChain `StructuredTool` objects for use with LangChain agents: + +```python +from sap_cloud_sdk.agentgateway import create_client +from sap_cloud_sdk.agentgateway.converters import mcp_tool_to_langchain + +agw_client = create_client(tenant_subdomain="my-tenant") +tools = await agw_client.list_mcp_tools(user_token="user-jwt") + +langchain_tools = [ + mcp_tool_to_langchain( + t, + agw_client.call_mcp_tool, + get_user_token=lambda: request.headers["Authorization"], + ) + for t in tools +] + +# Use with LangChain agent +llm_with_tools = llm.bind_tools(langchain_tools) +``` + +--- + +For the complete API reference and more examples, see the [Agent Gateway user guide](https://github.com/SAP/cloud-sdk-python/blob/main/src/sap_cloud_sdk/agentgateway/user-guide.md) in the `cloud-sdk-python` repository. diff --git a/docs-python/features/agent-modules/agent-memory.mdx b/docs-python/features/agent-modules/agent-memory.mdx new file mode 100644 index 00000000000..84623d5f9fd --- /dev/null +++ b/docs-python/features/agent-modules/agent-memory.mdx @@ -0,0 +1,41 @@ +--- +id: agent-memory +title: Agent Memory Service +hide_title: false +hide_table_of_contents: false +sidebar_label: Agent Memory Service +description: Persist and retrieve conversation history and long-term semantic memories +keywords: + - sap + - cloud + - sdk + - python + - agent memory + - hana cloud + - conversation history +--- + +The Agent Memory Service provides a persistent, tenant-isolated store backed by SAP HANA Cloud. +It exposes two APIs: the **Messages API** for short-term conversation history per session, and the **Memories API** for long-term semantic storage with similarity search across sessions. + +:::note Version requirement +Agent Memory Service requires **`sap-cloud-sdk >= 0.36.0`**. +::: + +### Basic Setup + +Use `create_client()` to get a client with automatic credential detection: + +```python +from sap_cloud_sdk.agent_memory import create_client + +client = create_client() + +memories = client.list_memories(agent_id="my-agent", invoker_id="user-123") +print(f"Found {len(memories)} memories") +) +``` + +--- + +For the complete API reference and more examples, see the [Agent Memory user guide](https://github.com/SAP/cloud-sdk-python/blob/main/src/sap_cloud_sdk/agent_memory/user-guide.md) in the `cloud-sdk-python` repository. diff --git a/docs-python/features/agent-modules/ai-core.mdx b/docs-python/features/agent-modules/ai-core.mdx new file mode 100644 index 00000000000..e5f0d33c0f5 --- /dev/null +++ b/docs-python/features/agent-modules/ai-core.mdx @@ -0,0 +1,41 @@ +--- +id: ai-core +title: SAP AI Core +hide_title: false +hide_table_of_contents: false +sidebar_label: SAP AI Core +description: Manage AI scenarios, deployments, and executions with the SAP AI Core Python client +keywords: + - sap + - cloud + - sdk + - python + - ai core + - deployments + - executions +--- + +The AI Core module provides a Python client for [SAP AI Core](https://help.sap.com/docs/sap-ai-core), enabling you to manage AI scenarios, deployments, and executions from your application. +The SDK handles credential resolution and authentication automatically via the service binding. + +### Basic Setup + +Use `set_aicore_config()` to automatically load and configure AI Core credentials: + +```python +from sap_cloud_sdk.aicore import set_aicore_config + +# Load credentials and configure environment for AI Core +set_aicore_config() + +# Now use LiteLLM with AI Core +from litellm import completion + +response = completion( + model="sap/gpt-4", messages=[{"role": "user", "content": "Hello!"}] +) +``` + +--- + +For the complete API reference and more examples, see the [AI Core user guide](https://github.com/SAP/cloud-sdk-python/blob/main/src/sap_cloud_sdk/aicore/user-guide.md) in the `cloud-sdk-python` repository. diff --git a/docs-python/features/agent-modules/tool-decorators.mdx b/docs-python/features/agent-modules/tool-decorators.mdx new file mode 100644 index 00000000000..ccb8f6966e3 --- /dev/null +++ b/docs-python/features/agent-modules/tool-decorators.mdx @@ -0,0 +1,65 @@ +--- +id: tool-decorators +title: Agent Decorators +hide_title: false +hide_table_of_contents: false +sidebar_label: Agent Decorators +description: Expose agent configuration fields to a low-code UI using Python decorators +keywords: + - sap + - cloud + - sdk + - python + - agent + - decorator + - configuration +--- + +The Agent Decorators module provides a configuration-as-code system for SAP AI agents. +Annotate Python functions with decorators to expose configuration fields — prompts, model selections, and settings — to a low-code UI. + +### Quick Start + +```python +from sap_cloud_sdk.agent_decorators import prompt_section, agent_model + + +# Define a prompt with a coded default +@prompt_section( + key="prompts.system", + label="System Prompt", + description="Main system prompt for the agent", +) +def system_prompt() -> str: + return "You are a helpful assistant." + + +# Define the model selection +@agent_model(key="config.model", label="LLM Model") +def model_name() -> str: + return "gpt-4" +``` + +### Decorators + +#### @prompt_section + +Expose a prompt section for editing. + +```python +from sap_cloud_sdk.agent_decorators import prompt_section + + +@prompt_section( + key="prompts.identity", + label="Agent Identity", + description="Core identity and role definition", + validation={"format": "text", "max_length": 500}, +) +def identity_prompt() -> str: + return "You are an expert assistant specializing in SAP systems." +``` + +--- + +For the complete API reference and more examples, see the [Agent Decorators user guide](https://github.com/SAP/cloud-sdk-python/blob/main/src/sap_cloud_sdk/agent_decorators/user-guide.md) in the `cloud-sdk-python` repository. diff --git a/docs-python/features/connectivity/destination-service.mdx b/docs-python/features/connectivity/destination-service.mdx new file mode 100644 index 00000000000..e58d42e28e6 --- /dev/null +++ b/docs-python/features/connectivity/destination-service.mdx @@ -0,0 +1,34 @@ +--- +id: destination-service +title: Destination Service +hide_title: false +hide_table_of_contents: false +sidebar_label: Destination Service +description: Connect to remote systems and resolve credentials using the SAP BTP Destination Service +keywords: + - sap + - cloud + - sdk + - python + - destination + - connectivity + - oauth +--- + +The Destination Service module provides an abstraction for connecting to remote systems defined in the SAP BTP Cockpit. +It resolves credentials, handles OAuth flows, and supports both cloud and on-premise systems via the SAP Connectivity Service. + +### Fetching a Destination + +```python +from sap_cloud_sdk.destination import DestinationService + +service = DestinationService() +destination = service.get_destination("my-destination") +``` + +The SDK supports all standard destination authentication types: Basic, OAuth 2.0 Client Credentials, OAuth 2.0 Authorization Code, and Principal Propagation. + +--- + +For the complete API reference and more examples, see the [Destination Service user guide](https://github.com/SAP/cloud-sdk-python/blob/main/src/sap_cloud_sdk/destination/user-guide.md) in the `cloud-sdk-python` repository. diff --git a/docs-python/features/connectivity/identity-ias.mdx b/docs-python/features/connectivity/identity-ias.mdx new file mode 100644 index 00000000000..cf3e1141f0e --- /dev/null +++ b/docs-python/features/connectivity/identity-ias.mdx @@ -0,0 +1,57 @@ +--- +id: identity-ias +title: Identity and Access Service (IAS) +hide_title: false +hide_table_of_contents: false +sidebar_label: Identity (IAS) +description: Parse and inspect IAS JWTs from SAP Cloud Identity Services +keywords: + - sap + - cloud + - sdk + - python + - ias + - identity + - jwt + - authentication +--- + +The IAS module provides utilities for working with SAP Identity Authentication Service (IAS) tokens. + +### Parsing a Token + +Use `parse_token` to decode an IAS JWT into a typed `IASClaims` dataclass. +It accepts either a raw token string or an `Authorization: Bearer ` header value. + +```python +from sap_cloud_sdk.ias import parse_token + +claims = parse_token( + request.headers["Authorization"] +) # accepts "Bearer " or raw token + +print(claims.app_tid) # tenant ID (multitenant scenarios) +print(claims.scim_id) # SCIM-based user ID in SAP Cloud Identity Services +print(claims.sub) # OIDC subject identifier +print(claims.email) # user email (when email scope was requested) +``` + +:::note +`parse_token` does **not** verify the token signature. +Validate the token against the IAS JWKS endpoint in your framework or middleware before using the extracted claims for authorization decisions. +::: + +### Combining with Telemetry + +```python +from sap_cloud_sdk.ias import parse_token +from sap_cloud_sdk.core.telemetry import set_tenant_id, add_span_attribute + +claims = parse_token(token) +set_tenant_id(claims.app_tid or "") +add_span_attribute("enduser.id", claims.scim_id or claims.sub or "") +``` + +--- + +For the complete claims reference and more examples, see the [IAS user guide](https://github.com/SAP/cloud-sdk-python/blob/main/src/sap_cloud_sdk/ias/user-guide.md) in the `cloud-sdk-python` repository. diff --git a/docs-python/features/connectivity/secret-management.mdx b/docs-python/features/connectivity/secret-management.mdx new file mode 100644 index 00000000000..84c8cf58a29 --- /dev/null +++ b/docs-python/features/connectivity/secret-management.mdx @@ -0,0 +1,58 @@ +--- +id: secret-management +title: Secret Resolver +hide_title: false +hide_table_of_contents: false +sidebar_label: Secret Resolver +description: Read service credentials and secrets from SAP BTP service bindings or environment variables +keywords: + - sap + - cloud + - sdk + - python + - secrets + - credentials + - service binding + - vcap +--- + +This module provides secure credential management by loading secrets from mounted volumes (Kubernetes-style) with fallback to environment variables. It supports type-safe configuration using dataclasses and follows Cloud patterns for secret resolution. + +The Secret Resolver is designed to work seamlessly in both Kubernetes environments with mounted secrets and with environment variables. + +### Getting Started + +The Secret Resolver loads configuration into dataclass objects using a hierarchical approach: + +- **First:** Try to read from mounted volume paths (Kubernetes secrets) +- **Fallback:** Use environment variables if mounted secrets are not available + +```python +from dataclasses import dataclass +from sap_cloud_sdk.secret_resolver import read_from_mount_and_fallback_to_env_var + + +@dataclass +class DatabaseConfig: + host: str = "" + port: str = "" + username: str = "" + password: str = "" + + +# Load configuration +config = DatabaseConfig() +read_from_mount_and_fallback_to_env_var( + base_volume_mount="/etc/secrets", # Base mount path + base_var_name="DB", # Environment variable prefix + module="database", # Module/service name + instance="primary", # Instance name + target=config, # Target dataclass instance +) + +print(f"Database: {config.username}@{config.host}:{config.port}") +``` + +--- + +For the complete API reference and more examples, see the [Secret Resolver user guide](https://github.com/SAP/cloud-sdk-python/blob/main/src/sap_cloud_sdk/core/secret_resolver/user-guide.md) in the `cloud-sdk-python` repository. diff --git a/docs-python/features/core-modules/audit-logging.mdx b/docs-python/features/core-modules/audit-logging.mdx new file mode 100644 index 00000000000..ecf1e7a0b65 --- /dev/null +++ b/docs-python/features/core-modules/audit-logging.mdx @@ -0,0 +1,55 @@ +--- +id: audit-logging +title: Audit Logging +hide_title: false +hide_table_of_contents: false +sidebar_label: Audit Logging +description: Emit structured audit log events to the SAP Audit Log Service from your Python application +keywords: + - sap + - cloud + - sdk + - python + - audit log + - compliance + - gdpr +--- + +The Audit Logging module provides a unified API for logging audit events that comply with the SAP Audit Log Service OpenAPI specification. +It uses Python dataclasses for type-safe event construction and supports six event types: Security, Data Access, Data Modification, Data Deletion, Configuration Change, and Configuration Deletion. + +### Basic Setup + +Use `create_client(tenant="my-tenant-subdomain")` to get a client with automatic environment detection: + +```python +from sap_cloud_sdk.core.auditlog import create_client, SecurityEvent + +client = create_client(tenant="my-tenant-subdomain") + +# Create and log a security event +security_event = SecurityEvent( + data="User login attempt", success=True, user="john.doe", tenant=Tenant.PROVIDER +) + +client.log(security_event) +``` + +### Custom Configuration + +```python +from sap_cloud_sdk.core.auditlog import create_client, AuditLogConfig + +config = AuditLogConfig( + service_url="https://api.auditlog.cf.example.com/audit-log/oauth2/v2", + oauth_url="https://example.authentication.com/oauth/token", + client_id="your-client-id", + client_secret="your-client-secret", +) + +client = create_client(config=config) +``` + +--- + +For all event types, batch logging, and configuration details, see the [Audit Logging user guide](https://github.com/SAP/cloud-sdk-python/blob/main/src/sap_cloud_sdk/core/auditlog/user-guide.md) in the `cloud-sdk-python` repository. diff --git a/docs-python/features/core-modules/object-storage.mdx b/docs-python/features/core-modules/object-storage.mdx new file mode 100644 index 00000000000..675d663757b --- /dev/null +++ b/docs-python/features/core-modules/object-storage.mdx @@ -0,0 +1,45 @@ +--- +id: object-storage +title: Object Storage +hide_title: false +hide_table_of_contents: false +sidebar_label: Object Storage +description: Upload, download, list, and delete objects with the SAP BTP Object Store Service +keywords: + - sap + - cloud + - sdk + - python + - object storage + - object store + - files +--- + +The Object Storage module provides a client for SAP BTP Object Store Service with a simple, unified API for uploading, downloading, listing, and deleting objects. + +### Getting Started + +Use `create_client()` to get a client with automatic configuration detection: + +```python +from sap_cloud_sdk.objectstore import create_client + +# Automatically detects local vs cloud mode +client = create_client("my-instance") +``` + +You can also specify additional parameters if needed: + +```python +from sap_cloud_sdk.objectstore import create_client + +# Custom configuration with SSL disabled +client = create_client( + "my-instance", + disable_ssl=True, # Disable SSL (default is False) +) +``` + +--- + +For error handling, metadata inspection, and configuration details, see the [Object Storage user guide](https://github.com/SAP/cloud-sdk-python/blob/main/src/sap_cloud_sdk/objectstore/user-guide.md) in the `cloud-sdk-python` repository. diff --git a/docs-python/features/core-modules/runtime-context.mdx b/docs-python/features/core-modules/runtime-context.mdx new file mode 100644 index 00000000000..2372224421f --- /dev/null +++ b/docs-python/features/core-modules/runtime-context.mdx @@ -0,0 +1,64 @@ +--- +id: runtime-context +title: Runtime Context +hide_title: false +hide_table_of_contents: false +sidebar_label: Runtime Context +description: Propagate tenant, user, and trigger-type context across async tasks without framework coupling +keywords: + - sap + - cloud + - sdk + - python + - runtime context + - tenant + - multi-tenancy + - context propagation +--- + +### How it works + +The runtime context lets SDK modules read caller-identity information (tenant, user, trigger type) for the current execution — without knowing where that information came from or what framework is running. + +- **bootstrap(app)** wires the SDK into your framework once at startup. +- **Providers** extract context from the current invocation (HTTP request, gRPC call, Kubernetes event, etc.). +- **get_context()** lets any module read that context via typed keys. + +```python +bootstrap(app) + └─ registers middleware on your framework + └─ on each invocation: providers extract → RuntimeContext set in ContextVar + └─ anywhere: get_context().get(TENANT_ID) +``` + +### Bootstrap at app startup + +```python +from starlette.applications import Starlette +from sap_cloud_sdk import bootstrap + +app = Starlette(...) +bootstrap(app) +``` + +### Read context anywhere + +```python +from sap_cloud_sdk.core.runtime_context import ( + get_context, + TENANT_ID, + USER_ID, + TRIGGER_TYPE, +) + +ctx = get_context() +ctx.get(TENANT_ID) # -> "abc-123" or None +ctx.get(USER_ID) # -> "user-uuid" or None +ctx.get(TRIGGER_TYPE) # -> "ui5" or None +``` + +Pass an explicit `tenant_id` parameter on any client that exposes one to override the context-resolved value for administrative or background processing scenarios. + +--- + +For framework adapters, provider merging semantics, and more, see the [Runtime Context user guide](https://github.com/SAP/cloud-sdk-python/blob/main/src/sap_cloud_sdk/core/runtime_context/user-guide.md) in the `cloud-sdk-python` repository. diff --git a/docs-python/features/core-modules/telemetry.mdx b/docs-python/features/core-modules/telemetry.mdx new file mode 100644 index 00000000000..d802f2540ee --- /dev/null +++ b/docs-python/features/core-modules/telemetry.mdx @@ -0,0 +1,41 @@ +--- +id: telemetry +title: Telemetry & Observability +hide_title: false +hide_table_of_contents: false +sidebar_label: Telemetry & Observability +description: Auto-instrument your application with OpenTelemetry traces and metrics for SAP Cloud Logging +keywords: + - sap + - cloud + - sdk + - python + - telemetry + - opentelemetry + - tracing + - observability +--- + +The Telemetry module provides observability utilities built on [OpenTelemetry](https://opentelemetry.io/). +It auto-instruments SDK HTTP clients and common Python frameworks (httpx, requests, starlette, fastapi, django, flask, sqlalchemy, grpcio), exporting traces, metrics, and logs to any OTLP-compatible backend such as SAP Cloud Logging. + +### Auto-Instrumentation and Agent Spans + +Call `auto_instrument()` once **before** importing AI libraries, then wrap LLM calls with a parent span that carries your business context: + +```python +from sap_cloud_sdk.core.telemetry import auto_instrument, invoke_agent_span + +auto_instrument() + +from litellm import completion # imported after — now automatically traced + +with invoke_agent_span( + provider="openai", agent_name="SupportBot", conversation_id="conv-123" +): + response = completion(model="gpt-4o", messages=[...]) +``` + +--- + +For span functions, extension context propagation, middleware, and configuration details, see the [Telemetry user guide](https://github.com/SAP/cloud-sdk-python/blob/main/src/sap_cloud_sdk/core/telemetry/user-guide.md) in the `cloud-sdk-python` repository. diff --git a/docs-python/features/rbs-services/adms.mdx b/docs-python/features/rbs-services/adms.mdx new file mode 100644 index 00000000000..f16e648559e --- /dev/null +++ b/docs-python/features/rbs-services/adms.mdx @@ -0,0 +1,59 @@ +--- +id: adms +title: ADMS +hide_title: false +hide_table_of_contents: false +sidebar_label: ADMS +description: Interact with the SAP Advanced Document Management Service OData V4 API from Python +keywords: + - sap + - cloud + - sdk + - python + - adms + - advanced document management + - odata +--- + +The ADMS module provides a typed Python client for the [SAP Advanced Document Management Service](https://help.sap.com/docs/advanced-document-management) OData V4 API. +Credentials are read from the service binding at `/etc/secrets/appfnd/adms/default/` or the `CLOUD_SDK_CFG_ADMS_DEFAULT_*` environment variables. + +### Quick Start + +```python +from sap_cloud_sdk.adms import ( + create_client, + AdmsConfig, + BaseType, + CreateDocumentInput, + CreateDocumentRelationInput, + ScanStatus, +) + +# Reads binding from /etc/secrets/appfnd/adms/default/ or env vars +client = create_client() + +# Link a document to a business object (creates a draft relation + document) +relation = client.relations.create( + CreateDocumentRelationInput( + business_object_node_type_unique_id="PurchaseOrder", + host_business_object_node_id="PO-4500012345", + document=CreateDocumentInput( + document_name="Invoice.pdf", + document_base_type=BaseType.DOCUMENT, + document_type_id="INVOICE", + ), + is_active_entity=False, # start as draft + ) +) + +# Upload bytes to the presigned URL (outside SDK) +import requests + +upload_url = relation.document.document_content_upload_urls[0] +requests.put(upload_url, data=open("Invoice.pdf", "rb")) +``` + +--- + +For draft workflows, background jobs, the async client, and more, see the [ADMS user guide](https://github.com/SAP/cloud-sdk-python/blob/main/src/sap_cloud_sdk/adms/user-guide.md) in the `cloud-sdk-python` repository. diff --git a/docs-python/features/rbs-services/dms.mdx b/docs-python/features/rbs-services/dms.mdx new file mode 100644 index 00000000000..23339a28923 --- /dev/null +++ b/docs-python/features/rbs-services/dms.mdx @@ -0,0 +1,51 @@ +--- +id: dms +title: DMS +hide_title: false +hide_table_of_contents: false +sidebar_label: DMS +description: Manage documents and folders in a repository with the SAP Document Management Service +keywords: + - sap + - cloud + - sdk + - python + - dms + - document management +--- + +The DMS module provides a Python client for the [SAP Document Management Service](https://help.sap.com/docs/document-management-service), enabling you to manage repositories, documents, folders, versioning, and access control via the CMIS Browser Binding protocol. + +### Creating a Client + +Use `create_client()` to get a client with automatic configuration detection: + +```python +from sap_cloud_sdk.dms import create_client + +# Load credentials from mounted secrets or environment variables +client = create_client(instance="my-instance") +``` + +You can also provide credentials directly: + +```python +from sap_cloud_sdk.dms import create_client +from sap_cloud_sdk.dms.model import DMSCredentials + +creds = DMSCredentials( + instance_name="my-instance", + uri="https://api-sdm-di.cfapps.eu10.hana.ondemand.com", + client_id="your-client-id", + client_secret="your-client-secret", + token_url="https://your-subdomain.authentication.eu10.hana.ondemand.com/oauth/token", + identityzone="your-subdomain", +) + +client = create_client(dms_cred=creds) +) +``` + +--- + +For repository management, versioning, access control, and more, see the [DMS user guide](https://github.com/SAP/cloud-sdk-python/blob/main/src/sap_cloud_sdk/dms/user-guide.md) in the `cloud-sdk-python` repository. diff --git a/docs-python/features/rbs-services/output-management.mdx b/docs-python/features/rbs-services/output-management.mdx new file mode 100644 index 00000000000..f2ab14f9ad1 --- /dev/null +++ b/docs-python/features/rbs-services/output-management.mdx @@ -0,0 +1,53 @@ +--- +id: output-management +title: Output Management Service +hide_title: false +hide_table_of_contents: false +sidebar_label: Output Management Service +description: Create and send output requests via the SAP Output Management Service +keywords: + - sap + - cloud + - sdk + - python + - output management + - email + - print +--- + +The Output Management module provides a client for creating and sending output requests — including emails and print documents — via the [SAP Output Management Service](https://help.sap.com/docs/output-management). + +### Quick Start + +Here's the simplest way to send an email: + +```python +from sap_cloud_sdk.outputmanagement import create_client + +# Create client using the factory function +client = create_client(destination_name="ARIBA_OUTPUT_SERVICE") + +# Send email directly +response = client.send_email( + notification_template_key="PO_APPROVAL_NOTIFICATION", + to=["finance@company.com"], + business_document={ + "PurchaseOrder": { + "orderId": "PO-12345", + "vendor": "ACME Corp", + "total": 1500.00, + } + }, +) + +# Check the result +if response.error: + print(f"Failed to send email: {response.error.message}") +else: + print(f"Email sent successfully! Request ID: {response.outputRequestId}") +) +``` + +--- + +For the complete API reference and more examples, see the [Output Management user guide](https://github.com/SAP/cloud-sdk-python/blob/main/src/sap_cloud_sdk/outputmanagement/user-guide.md) in the `cloud-sdk-python` repository. diff --git a/docs-python/features/rbs-services/print-service.mdx b/docs-python/features/rbs-services/print-service.mdx new file mode 100644 index 00000000000..65d365a2d58 --- /dev/null +++ b/docs-python/features/rbs-services/print-service.mdx @@ -0,0 +1,48 @@ +--- +id: print-service +title: Print Service +hide_title: false +hide_table_of_contents: false +sidebar_label: Print Service +description: Manage print queues, upload documents, and submit print tasks with the SAP Print Service +keywords: + - sap + - cloud + - sdk + - python + - print service + - print queue +--- + +The Print Service module provides a client for the [SAP Print Service](https://help.sap.com/docs/print-service), enabling you to manage print queues, upload documents, and submit print tasks. + +### Getting Started + +Use `create_client()` to get a client with automatic configuration detection: + +```python +from sap_cloud_sdk.print import create_client + +# Load credentials from mounted secrets or environment variables +client = create_client(instance="my-instance") +``` + +You can also provide credentials directly: + +```python +from sap_cloud_sdk.print import create_client +from sap_cloud_sdk.print.config import PrintConfig + +config = PrintConfig( + url="https://api.eu10.print.services.sap", + client_id="your-client-id", + client_secret="your-client-secret", + token_url="https://your-subdomain.authentication.eu10.hana.ondemand.com/oauth/token", +) + +client = create_client(config=config) +``` + +--- + +For print profiles and more examples, see the [Print Service user guide](https://github.com/SAP/cloud-sdk-python/blob/main/src/sap_cloud_sdk/print/user-guide.md) in the `cloud-sdk-python` repository. diff --git a/docs-python/getting-started.mdx b/docs-python/getting-started.mdx new file mode 100644 index 00000000000..d142b9644c3 --- /dev/null +++ b/docs-python/getting-started.mdx @@ -0,0 +1,38 @@ +--- +id: getting-started +title: Getting Started +hide_title: false +hide_table_of_contents: false +sidebar_label: Getting Started +description: Get up to speed with the SAP Cloud SDK for Python in no time +keywords: + - sap + - cloud + - sdk + - cloud native + - cloud sdk + - sap cloud sdk + - python +--- + +## What is the SAP Cloud SDK + +The SAP Cloud SDK is a set of libraries that helps you end-to-end when developing applications on SAP Business Technology Platform that communicate with SAP solutions and services such as SAP S/4HANA, SAP S/4HANA Cloud, SAP SuccessFactors, and many others. + +## Installation + +Install the SAP Cloud SDK for Python from [PyPI](https://pypi.org/project/sap-cloud-sdk/): + +```bash +pip install sap-cloud-sdk +``` + +## Sample Projects + +- In the future we aim to offer project samples to help customers using the Cloud SDK for Python. + +## Tutorials + +Check out the tutorials to get started with the SAP Cloud SDK for Python. + +- In the future we aim to offer tutorials to help customers understand how to use the Cloud SDK for Python. diff --git a/docs-python/overview.mdx b/docs-python/overview.mdx new file mode 100644 index 00000000000..fca7e2db79e --- /dev/null +++ b/docs-python/overview.mdx @@ -0,0 +1,73 @@ +--- +id: overview +title: Overview +hide_title: false +hide_table_of_contents: false +sidebar_label: Overview +description: The SAP Cloud SDK for Python provides building blocks for cloud-native AI agents and BTP integrations on SAP BTP +keywords: + - sap + - cloud + - sdk + - cloud native + - cloud sdk + - sap cloud sdk + - python +--- + +import useBaseUrl from '@docusaurus/useBaseUrl'; +import ThemedImage from '@theme/ThemedImage'; + +## Quick Start + +For a quick start check out the ["Getting Started"](./getting-started.mdx) page. + +## What is the SAP Cloud SDK for JavaScript? + +The SAP Cloud SDK for Python provides building blocks for cloud-native AI agents and BTP integrations — type-safe clients for destinations, identity, storage, telemetry, audit logging, and more. +Install with `pip install sap-cloud-sdk`. + + + +## Modules + +### Agent Modules + +Building blocks for AI-powered agents on SAP BTP: the **Agent Decorators** expose configuration fields (prompts, model, settings) to a low-code UI; the **Agent Gateway** discovers MCP tools from connected LoB systems with tenant-aware principal propagation; the **Agent Memory** service stores conversation history and long-term semantic memories backed by SAP HANA Cloud; and the **AI Core** client manages deployments and executions. + +→ [Agent Modules](features/agent-modules/tool-decorators) + +### Connectivity & Identity + +The **Destination Service** resolves credentials and handles OAuth flows (client credentials, principal propagation) for cloud and on-premise systems. The **IAS** module parses SAP Identity Authentication Service tokens into typed claims. The **Secret Resolver** loads service credentials from mounted volumes (Kubernetes) or environment variables (Cloud Foundry / local). + +→ [Connectivity & Identity](features/connectivity/destination-service) + +### Core Modules + +Cross-cutting utilities for any application type: **Audit Logging** emits structured events to the SAP Audit Log Service; **Telemetry** auto-instruments traces and metrics for SAP Cloud Logging via OpenTelemetry; **Object Storage** manages files on SAP BTP Object Store Service; and the **Runtime Context** propagates tenant, user, and trigger-type across async tasks without framework coupling. + +→ [Core Modules](features/core-modules/audit-logging) + +### RBS Services + +Clients for SAP RBS services: **DMS** for document and folder management (CMIS), **ADMS** for the Advanced Document Management OData V4 API, **Output Management** for sending output requests, and the **Print Service** for managing queues and submitting print tasks. + +→ [RBS Services](features/rbs-services/dms) + +## Requirements & Links + +- **Python:** 3.11, 3.12, or 3.13 +- **Environments:** SAP BTP Cloud Foundry, Kubernetes / SAP Gardener, SAP BTP Kyma, Deploy with Confidence (DwC) +- **License:** [Apache 2.0](https://github.com/SAP/cloud-sdk-python/blob/main/LICENSE) +- **PyPI:** [sap-cloud-sdk](https://pypi.org/project/sap-cloud-sdk/) +- **Release notes:** [Changelog](./release-notes.mdx) +- **Contributing:** [Contribution guide](https://github.com/SAP/cloud-sdk/blob/main/CONTRIBUTING.md) diff --git a/docs-python/release-notes.mdx b/docs-python/release-notes.mdx new file mode 100644 index 00000000000..0d8078d9702 --- /dev/null +++ b/docs-python/release-notes.mdx @@ -0,0 +1,107 @@ +--- +id: release-notes +title: Release Notes +sidebar_label: Release Notes +description: Release notes of the SAP Cloud SDK for Python, stay up to date with the recent features, fixes, dependency updates, and recommendations. +keywords: + - sap + - cloud + - sdk + - cloud-native + - cloud sdk + - sap cloud sdk + - python +--- + + + + +:::info v1.0.0 Release Candidate Coming Soon +We are working toward the first stable release of the SAP Cloud SDK for Python. +A **v1.0.0 release candidate** will be published in the near future, marking the stabilization of the public APIs. +If you are evaluating the SDK, we encourage you to test the latest pre-release version and share feedback via [GitHub Issues](https://github.com/SAP/cloud-sdk-python/issues). +::: + +## 0.43.2 - August 12, 2026 + +### Improvements + +- Renamed OpenTelemetry resource attribute `sap.cld.subaccount_id` to `sap.cloud.provider.subaccount_id` to align with SAP cloud naming conventions. + +## 0.43.1 - August 12, 2026 + +### Fixed Issues + +- `AuthToken` now surfaces error messages returned by the Destination Service when the service response contains non-empty error fields. +- Improved token validation handling for error-carrying tokens with empty `type` or `value` fields. + +## 0.43.0 - August 10, 2026 + +### Compatibility Notes + +- The `APPFND_UMS_DESTINATION_NAME` environment variable has been removed. Use `ExtensibilityConfig(destination_name="...")` instead. +- The UMS destination name prefix changed from `sap-managed-runtime-ums-` to `sap-managed-runtime-ias-`. +- `APPFND_CONHOS_UMS_URL` is now required; the UMS base URL is no longer read from the destination's URL field. + +### Improvements + +- Deferred destination-name resolution failure to fetch time for clearer error reporting. +- Enhanced error messaging for misconfigured extensibility settings. + +## 0.42.0 - August 7, 2026 + +### New Features + +- `bootstrap(app)` now automatically sets up telemetry as part of SDK runtime initialization — no separate telemetry configuration call needed. + +## 0.41.0 - August 7, 2026 + +### New Features + +- `list_mcp_tools()` on the Agent Gateway client now accepts an optional `MCPToolFilter` parameter to narrow discovered tools by name and/or ORD ID. + +## 0.40.1 - August 7, 2026 + +### Improvements + +- Updated OpenTelemetry core from 1.42.1 to 1.43.0. +- Updated OpenTelemetry instrumentation packages from 0.63b1 to 0.64b0. +- Updated Protobuf minimum requirement to `>=7.0.0`. + +## 0.40.0 - August 4, 2026 + +### New Features + +- New `sap_cloud_sdk.outputmanagement` module for integrating with the SAP Output Management Service. + Available operations: `send_email`, `send_email_with_mcp`, `create_output_request`, `send_output_request`. +- `DestinationCredentialConfig` now supports `PROVIDER_ONLY` and `SUBSCRIBER_ONLY` access strategies. +- Full OpenTelemetry telemetry support for the Output Management client. + +## 0.39.1 - August 3, 2026 + +### Fixed Issues + +- Agent Gateway: `get_mcp_tools_customer` now returns an empty list instead of raising an error when `integrationDependencies` is empty. +- Improved MCP server error logging to include HTTP status codes and response bodies. +- Improved tool invocation error logging. +- Fixed `streamable_http_client` unpacking compatibility. + +## 0.39.0 - July 24, 2026 + +### New Features + +- New `bootstrap(app)` entry point for SDK runtime initialization — replaces manual per-feature setup. +- New `sap_cloud_sdk.core.runtime_context` module with provider-agnostic context handling. + Supported context providers: `IASContextProvider`, `SAPTriggerContextProvider`, `DWCContextProvider`. +- `auto_instrument()` now automatically instruments supported HTTP clients, frameworks, and libraries including: httpx, requests, grpcio, Starlette, FastAPI, aiohttp, Django, Flask, SQLAlchemy, Redis, and logging. + +## 0.38.0 - July 22, 2026 + +### New Features + +- `AuditClient.send()` now auto-injects tenant and user context into audit log events. +- New `ias/_context.py` module exposing `set_auth_context` and `get_auth_context` APIs for IAS token propagation. + +### Improvements + +- `StarletteIASTelemetryMiddleware` refactored for improved token parsing reliability. diff --git a/docs-python/support.mdx b/docs-python/support.mdx new file mode 100644 index 00000000000..a1a305755e5 --- /dev/null +++ b/docs-python/support.mdx @@ -0,0 +1,27 @@ +--- +id: support +title: Support +sidebar_label: Support +description: If you're stuck and can't find a solution to your problem with SAP Cloud SDK for Python, we're here to help you. +keywords: + - sap + - cloud + - sdk + - cloud native + - cloud sdk + - sap cloud sdk + - python +--- + +:::caution +Be sure to remove **any confidential** information (examples: credentials or internal URLs) before publishing the issue on the internet. +::: + +## Support Channels + +### GitHub + +Please, create an issue in one of the public repositories of the SAP Cloud SDK. + +- **Python open source Repository**: ask a question, give feedback or create an issue [here](https://github.com/SAP/cloud-sdk-python/issues/new/choose). +- **Documentation**: request documentation or suggest fixes [here](https://github.com/SAP/cloud-sdk/issues/new/choose). diff --git a/docs-python/troubleshooting.mdx b/docs-python/troubleshooting.mdx new file mode 100644 index 00000000000..cd1e6252ba1 --- /dev/null +++ b/docs-python/troubleshooting.mdx @@ -0,0 +1,247 @@ +--- +id: troubleshooting +title: Troubleshooting +hide_title: false +hide_table_of_contents: false +sidebar_label: Troubleshooting +description: Troubleshooting guide for the SAP Cloud SDK for Python +keywords: + - sap + - cloud + - sdk + - cloud native + - cloud sdk + - sap cloud sdk + - python + - troubleshooting + - connectivity +--- + +## Solving Common Problems + +- Check if you are using the [latest release](./release-notes.mdx) — new fixes ship frequently. +- Search [Stack Overflow](https://stackoverflow.com/questions/tagged/sap-cloud-sdk) with the `sap-cloud-sdk` tag for solved issues. +- Check this page for known solutions to the most common problems. +- If nothing helps, [open an issue on GitHub](https://github.com/SAP/cloud-sdk-python/issues). + +--- + +## Installation + +### `pip install sap-cloud-sdk` Fails + +:::info Symptoms +The installation fails with a resolver error or a Python version warning. +::: + +Ensure you are using Python 3.11 or higher and that pip is up to date: + +```bash +python --version # must be 3.11+ +python -m pip install --upgrade pip +pip install sap-cloud-sdk +``` + +If you are working in a virtual environment, make sure it is activated before running the install command. + +### `ImportError` After Installation + +:::info Symptoms +`import sap_cloud_sdk` raises `ModuleNotFoundError` even though `pip install` succeeded. +::: + +The package was likely installed into a different Python interpreter than the one you are running. +Use `python -m pip` to guarantee the active interpreter is the target: + +```bash +python -m pip install sap-cloud-sdk +python -c "import sap_cloud_sdk; print(sap_cloud_sdk.__version__)" +``` + +### Dependency Conflict After Upgrading + +:::info Symptoms +After upgrading `sap-cloud-sdk`, an `ImportError` or `AttributeError` appears at runtime, or another package such as `a2a-sdk` stops working. +::: + +The SDK ships transitive dependencies at pinned versions. +Check for conflicting requirements with: + +```bash +pip check +``` + +If a conflict is reported, align the versions or use a fresh virtual environment. +You can also pin a known-good SDK version while waiting for a fix: + +```bash +pip install "sap-cloud-sdk==0.43.1" +``` + +--- + +## Connectivity and Destinations + +### Destination Not Found + +:::info Symptoms +`DestinationService.get_destination()` raises a not-found error at runtime. +::: + +**Possible causes:** + +- The destination name is misspelled — names are case-sensitive. +- When running locally, `VCAP_SERVICES` is not set. Export the JSON from the BTP Cockpit's service key and set it as an environment variable. +- The Destination Service binding is missing or misconfigured. Verify it is present in your `VCAP_SERVICES` or Kubernetes secret mount. + +### Authentication Failure (401 / 403) + +:::info Symptoms +Requests to a destination fail with HTTP 401 Unauthorized or 403 Forbidden. +::: + +**Possible causes:** + +- The credentials in the destination configuration are expired or incorrect. +- The authentication type configured on the destination does not match what the target system expects (for example, `BasicAuthentication` used where OAuth is required). +- The service key for the Destination Service lacks the required scopes. +- For OAuth destinations, verify the Token Service URL includes the full path, for example `/oauth/token`. + +### Client Certificates Not Applied + +:::info Symptoms +Requests succeed without client certificate authentication even though the destination is configured with `ClientCertificateAuthentication`. +::: + +This is a known issue tracked in [#254](https://github.com/SAP/cloud-sdk-python/issues/254). +As a workaround, attach the certificate manually to the HTTP client until the fix is available. + +--- + +## Agent Gateway Service + +### No MCP Tools Returned + +:::info Symptoms +`list_mcp_tools()` returns an empty list unexpectedly. +::: + +**Possible causes:** + +- The Agent Gateway formation is not yet in `READY` state for the current tenant. + Check the formation status in the SAP BTP Cockpit. +- `integrationDependencies` is empty in the ORD document — the tools have no declared dependencies to discover. +- The `user_token` passed to `list_mcp_tools()` is expired or invalid. + Ensure it is a callable that fetches a fresh token on each call, not a captured string: + +```python +# Correct — token resolved on every invocation +agw_client = create_client(tenant_subdomain=get_tenant_subdomain) +tools = await agw_client.list_mcp_tools(user_token=get_user_token) # callable + +# Incorrect — stale token captured at startup +token = get_user_token() +tools = await agw_client.list_mcp_tools(user_token=token) # string +``` + +### MCP Tool Call Result Is Truncated to a String + +:::info Symptoms +`call_mcp_tool()` returns a plain string instead of a structured object, losing nested data. +::: + +This is a known issue tracked in [#214](https://github.com/SAP/cloud-sdk-python/issues/214) — `CallToolResult` is flattened to `str`. +As a workaround, parse the returned string manually with `json.loads()`: + +```python +import json + +raw = await agw_client.call_mcp_tool(tool=tool, user_token=get_user_token, **args) +result = json.loads(raw) if isinstance(raw, str) else raw +``` + +### Duplicate Tool Names From Multiple MCP Servers + +:::info Symptoms +Two MCP servers expose a tool with the same name, causing the wrong tool to be called. +::: + +This is a known limitation tracked in [#208](https://github.com/SAP/cloud-sdk-python/issues/208). +Until resolved, use `MCPToolFilter` to scope tool discovery to a specific ORD ID: + +```python +from sap_cloud_sdk.agentgateway import AgentCardFilter + +tools = await agw_client.list_mcp_tools( + filter=MCPToolFilter(ord_ids=["sap.s4:purchaseOrder:v1"]) +) +``` + +### Missing Correlation ID in MCP Tool Error Logs + +:::info Symptoms +An MCP tool call fails but the error log does not include a correlation ID, making it hard to trace in SAP Cloud Logging. +::: + +This is a known issue tracked in [#195](https://github.com/SAP/cloud-sdk-python/issues/195). +In the meantime, extract the correlation ID from the response headers in your error handler and log it manually. + +--- + +## Agent Memory Service + +### `AgentMemoryConfigError` on Startup + +:::info Symptoms +`create_client()` raises `AgentMemoryConfigError` immediately, before any memory operation is attempted. +::: + +The HANA Agent Memory binding is not mounted. +Verify that `hanaAgentMemoryEnabled: true` is set in `app.yaml` and that the secret is mounted at `/etc/secrets/appfnd/hana-agent-memory/default`. + +For local development, set the following environment variables instead: + +```bash +export HC_API_URL=https://.hanacloud.ondemand.com +export HC_CLIENT_ID= +export HC_CLIENT_SECRET= +export HC_AUTH_URL=https:///oauth/token +``` + +### `AgentMemoryValidationError`: Missing Tenant + +:::info Symptoms +`create_client()` raises `AgentMemoryValidationError` with a message about a missing tenant argument. +::: + +Since v0.36.0, the `tenant` argument is required for subscriber-isolated clients. +Pass the current tenant's subdomain explicitly: + +```python +# Before v0.36 (no longer valid) +client = create_client() + +# v0.36+ — tenant subdomain is required +client = create_client(tenant=tenant_subdomain) +``` + +--- + +## Configuration and Breaking Changes + +### `APPFND_UMS_DESTINATION_NAME` No Longer Recognized (v0.43.0) + +:::info Symptoms +After upgrading to v0.43.0, the extensibility module fails to resolve the UMS destination. +::: + +The `APPFND_UMS_DESTINATION_NAME` environment variable was removed in v0.43.0. +Replace it with the programmatic config: + +```python +from sap_cloud_sdk.extensibility import ExtensibilityConfig + +config = ExtensibilityConfig(destination_name="my-ums-destination") +``` + +Also note that the UMS destination name prefix changed from `sap-managed-runtime-ums-` to `sap-managed-runtime-ias-`, and `APPFND_CONHOS_UMS_URL` is now required. diff --git a/docs/about.mdx b/docs/about.mdx index 33abc1a064d..2ba7b1889ad 100644 --- a/docs/about.mdx +++ b/docs/about.mdx @@ -24,6 +24,7 @@ The SAP Cloud SDK is available in two flavors: - [SAP Cloud SDK for Java](/docs/java/overview-cloud-sdk-for-java) - [SAP Cloud SDK for JavaScript](/docs/js/overview) +- [SAP Cloud SDK for Python](/docs/python/overview) ## Capabilities diff --git a/docusaurus.config.js b/docusaurus.config.js index b76d12bce94..e6c82612bc2 100644 --- a/docusaurus.config.js +++ b/docusaurus.config.js @@ -39,7 +39,7 @@ module.exports = { disableSwitch: true }, prism: { - additionalLanguages: ['powershell', 'java', 'groovy'], + additionalLanguages: ['powershell', 'java', 'groovy', 'python'], theme: require('prism-react-renderer').themes.github, darkTheme: require('prism-react-renderer').themes.dracula }, @@ -79,6 +79,14 @@ module.exports = { activeBasePath: 'docs/js', sdkSwitch: true }, + { + label: '🐍 Python', + to: 'docs/python/overview', + position: 'left', + docsPluginId: 'docs-python', + activeBasePath: 'docs/python', + sdkSwitch: true + }, { label: 'SAP Cloud SDK for AI', href: 'https://sap.github.io/ai-sdk', @@ -270,6 +278,23 @@ module.exports = { } } ], + [ + '@docusaurus/plugin-content-docs', + { + id: 'docs-python', + path: 'docs-python', + editUrl: 'https://github.com/SAP/cloud-sdk/edit/main', + routeBasePath: 'docs/python', + sidebarPath: require.resolve('./sidebarsDocsPython.js'), + lastVersion: 'current', + versions: { + current: { + label: 'v1', + badge: false + } + } + } + ], [ '@docusaurus/plugin-client-redirects', { diff --git a/sidebarsDocsPython.js b/sidebarsDocsPython.js new file mode 100644 index 00000000000..133c56fad9d --- /dev/null +++ b/sidebarsDocsPython.js @@ -0,0 +1,59 @@ +module.exports = { + docsPythonSidebar: [ + 'overview', + 'getting-started', + { + type: 'category', + label: 'Features', + collapsed: false, + items: [ + { + type: 'category', + label: 'Agent Modules', + collapsed: false, + items: [ + 'features/agent-modules/tool-decorators', + 'features/agent-modules/agent-gateway', + 'features/agent-modules/agent-memory', + 'features/agent-modules/ai-core' + ] + }, + { + type: 'category', + label: 'Connectivity & Identity', + collapsed: false, + items: [ + 'features/connectivity/destination-service', + 'features/connectivity/identity-ias', + 'features/connectivity/secret-management' + ] + }, + { + type: 'category', + label: 'Core Modules', + collapsed: false, + items: [ + 'features/core-modules/audit-logging', + 'features/core-modules/telemetry', + 'features/core-modules/object-storage', + 'features/core-modules/runtime-context' + ] + }, + { + type: 'category', + label: 'RBS Services', + collapsed: false, + items: [ + 'features/rbs-services/dms', + 'features/rbs-services/adms', + 'features/rbs-services/output-management', + 'features/rbs-services/print-service' + ] + } + ] + }, + 'release-notes', + 'support', + 'troubleshooting' + ] +}; diff --git a/src/components/JsFeatureTable.js b/src/components/JsFeatureTable.js index 0a465ab3d58..a953249ba93 100644 --- a/src/components/JsFeatureTable.js +++ b/src/components/JsFeatureTable.js @@ -1,9 +1,9 @@ import React from 'react'; import ReactMarkdown from 'react-markdown'; +import emoji from 'remark-emoji'; +import gfm from 'remark-gfm'; import { jsFeatureTableLayout } from './data/table-layouts'; // Table layour for JS feature matrix with bindings import { features } from './data/features'; -import gfm from 'remark-gfm'; -import emoji from 'remark-emoji'; import Table from './Table'; /** diff --git a/src/components/data/features.js b/src/components/data/features.js index c3641665c10..d993e13d23f 100644 --- a/src/components/data/features.js +++ b/src/components/data/features.js @@ -22,6 +22,11 @@ export const features = [ status: NO, docsLink: ``, note: 'Take a look at the [node-soap](https://github.com/vpulim/node-soap) library' + }, + python: { + status: NO, + docsLink: ``, + note: 'Out of scope' } }, { @@ -36,6 +41,11 @@ export const features = [ status: NO, docsLink: ``, note: 'Take a look at the [SAP NetWeaver RFC SDK client bindings for Node.js](https://github.com/SAP/node-rfc)' + }, + python: { + status: NO, + docsLink: ``, + note: 'Out of scope' } }, { @@ -50,6 +60,11 @@ export const features = [ status: NO, docsLink: ``, note: 'Take a look at the [SAP NetWeaver RFC SDK client bindings for Node.js](https://github.com/SAP/node-rfc)' + }, + python: { + status: NO, + docsLink: ``, + note: 'Out of scope' } }, { @@ -64,6 +79,11 @@ export const features = [ status: YES, docsLink: `[docs](${baseUrl}/js/features/odata/v2-client)`, note: '' + }, + python: { + status: NO, + docsLink: ``, + note: 'Out of scope' } }, { @@ -78,6 +98,11 @@ export const features = [ status: YES, docsLink: `[docs](${baseUrl}/js/features/odata/v4-client)`, note: '' + }, + python: { + status: NO, + docsLink: ``, + note: 'Out of scope' } }, { @@ -92,6 +117,11 @@ export const features = [ status: NO, docsLink: ``, note: `We expose [generic HTTP client](${baseUrl}/js/features/connectivity/http-client) aware of connectivity abstractions` + }, + python: { + status: NO, + docsLink: ``, + note: 'Use the HTTP Client wrapper with destination awareness instead' } }, { @@ -106,6 +136,11 @@ export const features = [ status: YES, docsLink: `[docs](${baseUrl}/js/features/odata/generate-client)`, note: '' + }, + python: { + status: NO, + docsLink: ``, + note: 'Out of scope' } }, { @@ -120,6 +155,11 @@ export const features = [ status: YES, docsLink: `[docs](${baseUrl}/js/features/openapi/execute-request)`, note: '' + }, + python: { + status: NO, + docsLink: ``, + note: 'Out of scope' } }, { @@ -134,6 +174,11 @@ export const features = [ status: YES, docsLink: `[docs](${baseUrl}/js/features/openapi/execute-request)`, note: '' + }, + python: { + status: NO, + docsLink: ``, + note: 'Out of scope' } }, { @@ -148,6 +193,11 @@ export const features = [ status: YES, docsLink: `[docs](${baseUrl}/js/features/openapi/generate-client)`, note: '' + }, + python: { + status: NO, + docsLink: ``, + note: 'Out of scope' } }, { @@ -162,6 +212,11 @@ export const features = [ status: NO, docsLink: ``, note: '' + }, + python: { + status: NO, + docsLink: ``, + note: '' } }, { @@ -176,6 +231,11 @@ export const features = [ status: YES, docsLink: `[docs](${baseUrl}/js/guides/resilience)`, note: '' + }, + python: { + status: NO, + docsLink: ``, + note: '' } }, { @@ -190,6 +250,11 @@ export const features = [ status: YES, docsLink: `[docs](${baseUrl}/js/features/connectivity/destination-cache)`, note: '' + }, + python: { + status: NO, + docsLink: ``, + note: '' } }, { @@ -204,6 +269,11 @@ export const features = [ status: YES, docsLink: `[docs](${baseUrl}/js/getting-started)`, note: '' + }, + python: { + status: NO, + docsLink: ``, + note: '' } }, { @@ -218,6 +288,11 @@ export const features = [ status: YES, docsLink: `[docs](${baseUrl}/js/environments/kubernetes)`, note: '' + }, + python: { + status: YES, + docsLink: ``, + note: '' } }, { @@ -232,6 +307,11 @@ export const features = [ status: YES, docsLink: `[docs](${baseUrl}/js/environments/kyma)`, note: '' + }, + python: { + status: YES, + docsLink: ``, + note: '' } }, { @@ -246,6 +326,11 @@ export const features = [ status: NO, docsLink: ``, note: '' + }, + python: { + status: YES, + docsLink: ``, + note: 'Via `DWCContextProvider` in `sap_cloud_sdk.core.runtime_context`' } }, { @@ -260,6 +345,11 @@ export const features = [ status: NO, docsLink: ``, note: 'Out of scope.' + }, + python: { + status: NO, + docsLink: ``, + note: 'Out of scope' } }, { @@ -274,6 +364,11 @@ export const features = [ status: NO, docsLink: '', note: 'Out of scope' + }, + python: { + status: NO, + docsLink: '', + note: 'Out of scope' } }, { @@ -288,6 +383,11 @@ export const features = [ status: YES, docsLink: `[docs](${baseUrl}/js/features/connectivity/destinations)`, note: '' + }, + python: { + status: YES, + docsLink: ``, + note: '' } }, { @@ -302,6 +402,11 @@ export const features = [ status: YES, docsLink: `[docs](${baseUrl}/js/features/connectivity/destinations)`, note: '' + }, + python: { + status: YES, + docsLink: ``, + note: '' } }, { @@ -316,6 +421,11 @@ export const features = [ status: YES, docsLink: `[docs](${baseUrl}/js/features/connectivity/destinations)`, note: '' + }, + python: { + status: NO, + docsLink: ``, + note: 'IAS is the primary identity provider;' } }, { @@ -330,6 +440,11 @@ export const features = [ status: YES, docsLink: ``, note: '' + }, + python: { + status: YES, + docsLink: ``, + note: 'Via [servicebinding.io](https://servicebinding.io/) spec and `SERVICE_BINDING_ROOT`' } }, { @@ -344,6 +459,11 @@ export const features = [ status: YES, docsLink: `[docs](${baseUrl}/js/features/connectivity/destinations#authentication-and-json-web-token-retrievjal)`, note: '' + }, + python: { + status: YES, + docsLink: ``, + note: 'OAuth flows handled via IAS module and Destination Service' } }, { @@ -358,6 +478,11 @@ export const features = [ status: YES, docsLink: `[docs](${baseUrl}/js/features/connectivity/destinations#multi-tenancy)`, note: '' + }, + python: { + status: YES, + docsLink: ``, + note: 'Tenant isolation applied throughout; `create_client(tenant=subdomain)` pattern' } }, { @@ -372,6 +497,11 @@ export const features = [ status: YES, docsLink: `[docs](${baseUrl}/js/features/connectivity/destinations#multi-tenancy)`, note: '' + }, + python: { + status: YES, + docsLink: ``, + note: '' } }, { @@ -386,6 +516,11 @@ export const features = [ status: YES, docsLink: `[docs](${baseUrl}/js/features/connectivity/http-client)`, note: '' + }, + python: { + status: YES, + docsLink: ``, + note: '`DestinationHttpClient` — destination-aware HTTP client' } }, { @@ -400,6 +535,11 @@ export const features = [ status: YES, docsLink: `[docs](${baseUrl}/js/features/connectivity/on-premise#principal-propagation)`, note: '' + }, + python: { + status: YES, + docsLink: ``, + note: 'User token exchange via IAS Destination Fragments' } }, { @@ -414,6 +554,11 @@ export const features = [ status: YES, docsLink: `[docs](${baseUrl}/js/features/connectivity/on-premise)`, note: '' + }, + python: { + status: NO, + docsLink: ``, + note: '' } }, { @@ -428,6 +573,202 @@ export const features = [ status: NO, docsLink: ``, note: '' + }, + python: { + status: NO, + docsLink: ``, + note: '' + } + }, + // Python-only features + { + name: '[Identity and Access Service (IAS)](https://help.sap.com/docs/identity-authentication)', + category: 'Connectivity', + java: { + status: NO, + docsLink: ``, + note: 'Out of scope' + }, + js: { + status: NO, + docsLink: ``, + note: 'Out of scope' + }, + python: { + status: YES, + docsLink: ``, + note: 'Token verification, user context propagation, service-to-service auth' + } + }, + { + name: '[Audit Logging](https://help.sap.com/docs/audit-log-service)', + category: 'Advanced', + java: { + status: NO, + docsLink: ``, + note: 'Out of scope' + }, + js: { + status: NO, + docsLink: ``, + note: 'Out of scope' + }, + python: { + status: YES, + docsLink: ``, + note: 'Standard and next-generation (NG) SAP Audit Log Service APIs supported' + } + }, + { + name: 'Telemetry / OpenTelemetry', + category: 'Advanced', + java: { + status: NO, + docsLink: ``, + note: 'Out of scope' + }, + js: { + status: NO, + docsLink: ``, + note: 'Out of scope' + }, + python: { + status: YES, + docsLink: ``, + note: 'Auto-instrumentation of HTTP clients and frameworks via `auto_instrument()`; exports to SAP Cloud Logging' + } + }, + { + name: 'Secret Management', + category: 'Advanced', + java: { + status: NO, + docsLink: ``, + note: 'Out of scope' + }, + js: { + status: NO, + docsLink: ``, + note: 'Out of scope' + }, + python: { + status: YES, + docsLink: ``, + note: 'Resolves secrets from Kubernetes-mounted bindings and env vars (`CLOUD_SDK_CFG_*`)' + } + }, + { + name: 'Object Storage', + category: 'BTP Services', + java: { + status: NO, + docsLink: ``, + note: 'Out of scope' + }, + js: { + status: NO, + docsLink: ``, + note: 'Out of scope' + }, + python: { + status: YES, + docsLink: ``, + note: '' + } + }, + { + name: 'Document Management Service', + category: 'BTP Services', + java: { + status: NO, + docsLink: ``, + note: 'Out of scope' + }, + js: { + status: NO, + docsLink: ``, + note: 'Out of scope' + }, + python: { + status: YES, + docsLink: ``, + note: '' + } + }, + { + name: 'Output Management Service', + category: 'BTP Services', + java: { + status: NO, + docsLink: ``, + note: 'Out of scope' + }, + js: { + status: NO, + docsLink: ``, + note: 'Out of scope' + }, + python: { + status: YES, + docsLink: ``, + note: 'Send emails, create and send output requests via `sap_cloud_sdk.outputmanagement`' + } + }, + { + name: '[SAP AI Core](https://help.sap.com/docs/sap-ai-core)', + category: 'AI', + java: { + status: NO, + docsLink: ``, + note: 'Out of scope' + }, + js: { + status: NO, + docsLink: ``, + note: 'Out of scope' + }, + python: { + status: YES, + docsLink: `[docs](${baseUrl}/python/overview)`, + note: 'Manage AI scenarios, deployments, and executions via `AICoreClient`' + } + }, + { + name: 'Agent Gateway Service', + category: 'AI', + java: { + status: NO, + docsLink: ``, + note: 'Out of scope' + }, + js: { + status: NO, + docsLink: ``, + note: 'Out of scope' + }, + python: { + status: YES, + docsLink: `[docs](${baseUrl}/python/overview)`, + note: 'MCP tool discovery from SAP LoB systems; A2A agent routing; principal propagation' + } + }, + { + name: 'Agent Memory Service', + category: 'AI', + java: { + status: NO, + docsLink: ``, + note: 'Out of scope' + }, + js: { + status: NO, + docsLink: ``, + note: 'Out of scope' + }, + python: { + status: YES, + docsLink: `[docs](${baseUrl}/python/overview)`, + note: 'Persistent conversation history and semantic memory search backed by SAP HANA Cloud' } } ]; diff --git a/src/components/data/table-layouts.js b/src/components/data/table-layouts.js index ad80d97891b..780c5ac7d79 100644 --- a/src/components/data/table-layouts.js +++ b/src/components/data/table-layouts.js @@ -51,6 +51,27 @@ export const mainFeatureTableLayout = [ accessorKey: 'js.note' } ] + }, + { + Header: 'SAP Cloud SDK Python', + id: 'python', + columns: [ + { + id: 'python-status', + Header: 'Status', + accessorKey: 'python.status' + }, + { + id: 'python-docs', + Header: 'Docs', + accessorKey: 'python.docsLink' + }, + { + id: 'python-notes', + Header: 'Notes', + accessorKey: 'python.note' + } + ] } ]; @@ -133,6 +154,7 @@ export const jsFeatureTableLayout = [ ] } ]; + export const ODataFeatureTableLayout = [ { header: 'Feature', diff --git a/src/pages/components/HomepageFeatures.js b/src/pages/components/HomepageFeatures.js index 27307928226..d2ed1e19737 100644 --- a/src/pages/components/HomepageFeatures.js +++ b/src/pages/components/HomepageFeatures.js @@ -43,6 +43,21 @@ const FeatureList = [ ) + }, + { + title: <>SAP Cloud SDK for Python, + link: 'docs/python/overview', + Svg: require('../../../static/img/logo-python.svg').default, + badge: , + description: ( +
+ The SAP Cloud SDK for Python helps you build cloud-native AI agents and + BTP integrations using Python, with built-in support for the Agent + Gateway, Agent Memory, and SAP BTP services. +
+ Get started with the SDK for Python +
+ ) } ]; diff --git a/static/img/logo-python.svg b/static/img/logo-python.svg new file mode 100644 index 00000000000..38f8787049a --- /dev/null +++ b/static/img/logo-python.svg @@ -0,0 +1,113 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +for Python + diff --git a/static/img/python-sdk-overview.svg b/static/img/python-sdk-overview.svg new file mode 100644 index 00000000000..158c8f5e6e5 --- /dev/null +++ b/static/img/python-sdk-overview.svg @@ -0,0 +1,78 @@ + + + + + + + Connectivity + & Identity + + + Destination Service + + + Identity (IAS) + + + Secret Resolver + + + + Core Modules + + + Audit Logging + + + Telemetry & Observability + + + Object Storage + + + Runtime Context + + + + Agent Modules + + + Agent Decorators + + + Agent Gateway + + + Agent Memory + + + SAP AI Core + + + + RBS Services + + + DMS + + + ADMS + + + Output Management + + + Print Service + +