Documentation Index
Fetch the complete documentation index at: https://docs.s4kit.com/llms.txt
Use this file to discover all available pages before exploring further.
S4Kit is currently in beta. We’re working with early adopters to refine the developer experience. Get early access →
SAP integration shouldn’t be this hard
Connecting to SAP S/4HANA typically means weeks of setup, complex authentication flows, and fighting with OData quirks. S4Kit changes that.
// The traditional way: 50+ lines of boilerplate
import axios from 'axios';
// Step 1: Get CSRF token
const tokenResponse = await axios.get(
'https://sap-server.company.com/sap/opu/odata/sap/API_BUSINESS_PARTNER/A_BusinessPartner',
{
headers: {
'Authorization': `Basic ${Buffer.from(`${user}:${pass}`).toString('base64')}`,
'x-csrf-token': 'Fetch',
'sap-client': '100',
}
}
);
const csrfToken = tokenResponse.headers['x-csrf-token'];
const cookies = tokenResponse.headers['set-cookie'];
// Step 2: Make the actual request
const response = await axios.get(
'https://sap-server.company.com/sap/opu/odata/sap/API_BUSINESS_PARTNER/A_BusinessPartner',
{
params: {
'$select': 'BusinessPartner,BusinessPartnerName',
'$filter': "BusinessPartnerCategory eq '1'",
'$top': 10
},
headers: {
'Authorization': `Basic ${Buffer.from(`${user}:${pass}`).toString('base64')}`,
'x-csrf-token': csrfToken,
'Cookie': cookies.join('; '),
'sap-client': '100',
'Accept': 'application/json',
}
}
);
// Step 3: Parse the weird OData response format
const partners = response.data.d.results;
// The S4Kit way: Clean, type-safe, done.
import { S4Kit } from 's4kit';
const client = new S4Kit({
apiKey: process.env.S4KIT_API_KEY,
connection: 'production'
});
const partners = await client.A_BusinessPartner.list({
select: ['BusinessPartner', 'BusinessPartnerName'],
filter: "BusinessPartnerCategory eq '1'",
top: 10
});
Built for developers who value their time
5-Minute Setup
Install the SDK, add your API key, start querying SAP. No SAP expertise required.
Type-Safe
Full TypeScript support. Generate types from your SAP metadata. Catch errors at compile time.
Stripe-like DX
Simple API keys instead of certificates. Clear error messages. Predictable behavior.
Multi-Environment
Sandbox → Dev → QA → Production. Same code, different connection string.
Observable
Every request logged. Performance metrics. Error tracking. Full audit trail.
Secure by Design
Encrypted credentials. Granular permissions. Full audit trails.
How it works
You call the SDK
Your app uses the S4Kit SDK with a simple API key. No SAP credentials in your code.await client.A_SalesOrder.list({ top: 10 })
We handle the complexity
S4Kit authenticates to SAP, manages tokens, handles CSRF, retries on failure.
SAP responds
Your SAP system processes the request and returns data through our secure proxy.
You get clean JSON
No OData wrapper objects. No d.results. Just the data you asked for.
Everything you need
Create, read, update, and delete any SAP entity. Batch operations. Deep inserts. Navigation properties.// Create
const order = await client.A_SalesOrder.create({ ... });
// Read
const orders = await client.A_SalesOrder.list({ top: 100 });
// Update
await client.A_SalesOrder.update(orderId, { Status: 'C' });
// Delete
await client.A_SalesOrder.delete(orderId);
Full OData query support with a clean API. Filter, sort, paginate, expand relations.const orders = await client.A_SalesOrder.list({
select: ['SalesOrder', 'TotalNetAmount', 'SoldToParty'],
filter: "CreationDate ge 2024-01-01 and TotalNetAmount gt 10000",
orderBy: 'CreationDate desc',
expand: ['to_Item', 'to_Partner'],
top: 50
});
Generate TypeScript types from your SAP OData metadata. Full autocomplete in your IDE.npx s4kit generate-types --api-key sk_live_... --output ./types
Control exactly which entities and operations each API key can access.production:
API_BUSINESS_PARTNER:
A_BusinessPartner: [list, get]
A_BusinessPartnerAddress: [list, get]
API_SALES_ORDER_SRV:
A_SalesOrder: [list, get, create, update]
Start building in minutes
Quickstart Guide
Install the SDK and make your first SAP request in under 5 minutes.
SDK Reference
Complete guide to all SDK features, from basic queries to advanced patterns.
Platform Setup
Configure your SAP systems, manage API keys, and set up environments.
API Reference
REST API documentation for programmatic platform management.
Trusted by teams building on SAP
For Startups
For Enterprise
For Consultants
Skip the months of SAP learning curve. Ship your integration in days, not quarters. Focus on your product, not SAP plumbing.
Standardize SAP access across teams. Centralized audit logs. Granular access control. No more credential sprawl.
Deliver SAP integrations faster. Reusable patterns. Happy clients. More projects.
Ready to simplify your SAP integration?
Get started with S4Kit →