Integracje
Endpointy „Integracje” Zanfia Workspace API — ze schematami i przykładami kodu.
Połączenia z danymi dostępowymi stojące za Ustawienia → Integracje, pod dedykowanymi scope’ami integrations:read / integrations:write (klucz do produktów celowo nie może podpiąć bramki ani podmienić ESP): konta mailingowe (ActiveCampaign, Kit, MailerLite, MailChimp, GetResponse, Pipedrive — połączenie, odłączenie, odświeżenie list), ręczne wpisy Meta pixel + Conversions API oraz płatność ręczna (przelew). Klucze i tokeny są weryfikowane u dostawcy przed zapisem, trafiają do Secret Managera i nigdy nie są zwracane. Dostawcy OAuth (Stripe Connect, Meta OAuth, Google, social media) i bramki płatnicze z danymi logowania pozostają na razie tylko w panelu; integracje pikselowe (GA4, GTM, TikTok, X, LinkedIn, Clarity, Hotjar) są w sekcji Śledzenie konwersji. Wszystkie endpointy wymagają nagłówka Authorization: Bearer — zobacz Uwierzytelnianie.
Przegląd integracji
/integrationsAuthorization
bearerAuth API key from Dashboard → Integrations → API, MCP and CLI.
In: header
Response Body
application/json
application/json
curl -X GET "https://example.com/integrations"{ "emailClients": [ { "client": "ActiveCampaign", "url": "string", "name": "string", "listsCount": 0, "tagsCount": 0, "serverPrefix": "string", "createdAt": "string", "updatedAt": "string" } ], "metaConversionApi": [ { "id": "string", "name": "string", "pixelId": "string", "serverSide": true, "disabled": true, "isWorkspaceDefault": true, "trackPurchase": true, "trackInitCheckout": true, "trackAddToCart": true, "trackTrialStarted": true, "createdAt": "string", "updatedAt": "string" } ], "conversionTrackingIntegrationsCount": 0, "invoicesClients": [ { "client": "fakturownia", "id": "string", "url": "string", "createdAt": "string" } ], "payments": { "stripe": true, "payU": true, "tpay": true, "payNow": true, "przelewy24": true, "paypal": true, "dodo": true, "manual": { "name": "string", "instructions": "string", "updatedAt": "string" } }, "sms": { "defaultProvider": "twilio", "twilio": { "accountSid": "string", "region": "us1", "senderKind": "messagingService", "sender": "string", "senderLabel": "string" }, "smsapi": { "region": "pl", "sender": "string", "senders": [ "string" ], "accountName": "string", "needsReconnect": true } }}{ "error": "string", "message": "string"}Połącz klienta mailingowego
/integrations/email-clientsAuthorization
bearerAuth API key from Dashboard → Integrations → API, MCP and CLI.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
POST /integrations/email-clients — discriminated by client; the key is verified against the provider first.
POST /integrations/email-clients — discriminated by client; the key is verified against the provider first.
Response Body
application/json
application/json
curl -X POST "https://example.com/integrations/email-clients" \ -H "Content-Type: application/json" \ -d '{ "client": "ActiveCampaign", "url": "string", "apiKey": "string" }'{ "client": "ActiveCampaign", "url": "string", "name": "string", "listsCount": 0, "tagsCount": 0, "serverPrefix": "string", "createdAt": "string", "updatedAt": "string"}{ "error": "string", "message": "string"}Odłącz klienta mailingowego
/integrations/email-clients/disconnectAuthorization
bearerAuth API key from Dashboard → Integrations → API, MCP and CLI.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
POST /integrations/email-clients/disconnect — 409 account-in-use lists the products still using it.
Response Body
application/json
application/json
curl -X POST "https://example.com/integrations/email-clients/disconnect" \ -H "Content-Type: application/json" \ -d '{ "client": "ActiveCampaign", "url": "string" }'{ "status": "ok"}{ "error": "string", "message": "string"}Odśwież listy klienta mailingowego
/integrations/email-clients/refresh-listsAuthorization
bearerAuth API key from Dashboard → Integrations → API, MCP and CLI.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
POST /integrations/email-clients/refresh-lists — re-fetches lists + tags with the stored key.
POST /integrations/email-clients/refresh-lists — re-fetches lists + tags with the stored key.
Response Body
application/json
application/json
curl -X POST "https://example.com/integrations/email-clients/refresh-lists" \ -H "Content-Type: application/json" \ -d '{ "client": "ActiveCampaign", "url": "string" }'{ "client": "ActiveCampaign", "url": "string", "name": "string", "listsCount": 0, "tagsCount": 0, "serverPrefix": "string", "createdAt": "string", "updatedAt": "string"}{ "error": "string", "message": "string"}Dodaj lub edytuj wpis Meta pixel / Conversions API
/integrations/meta-conversion-apiAuthorization
bearerAuth API key from Dashboard → Integrations → API, MCP and CLI.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
PUT /integrations/meta-conversion-api — create (no id) or edit (with id) a manual Meta pixel + Conversions API entry. accessToken is validated against Meta before saving; omitted on edit = keep the stored token.
Response Body
application/json
application/json
curl -X PUT "https://example.com/integrations/meta-conversion-api" \ -H "Content-Type: application/json" \ -d '{ "pixelId": "string", "name": "string", "trackInitCheckout": true, "trackAddToCart": true, "trackPurchase": true }'{ "id": "string", "name": "string", "pixelId": "string", "serverSide": true, "disabled": true, "isWorkspaceDefault": true, "trackPurchase": true, "trackInitCheckout": true, "trackAddToCart": true, "trackTrialStarted": true, "createdAt": "string", "updatedAt": "string"}{ "error": "string", "message": "string"}Usuń wpis Meta pixel / Conversions API
/integrations/meta-conversion-api/{integrationId}Authorization
bearerAuth API key from Dashboard → Integrations → API, MCP and CLI.
In: header
Path Parameters
Response Body
application/json
application/json
curl -X DELETE "https://example.com/integrations/meta-conversion-api/string"{ "status": "ok"}{ "error": "string", "message": "string"}Skonfiguruj płatność ręczną (przelew)
/integrations/payments/manualAuthorization
bearerAuth API key from Dashboard → Integrations → API, MCP and CLI.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
PUT /integrations/payments/manual — configure the wire-transfer payment method.
Response Body
application/json
application/json
curl -X PUT "https://example.com/integrations/payments/manual" \ -H "Content-Type: application/json" \ -d '{ "name": "string", "instructions": "string" }'{ "name": "string", "instructions": "string", "updatedAt": "string"}{ "error": "string", "message": "string"}Usuń płatność ręczną
/integrations/payments/manualAuthorization
bearerAuth API key from Dashboard → Integrations → API, MCP and CLI.
In: header
Response Body
application/json
application/json
curl -X DELETE "https://example.com/integrations/payments/manual"{ "status": "ok"}{ "error": "string", "message": "string"}Połącz konto fakturowania
/integrations/invoices-clientsAuthorization
bearerAuth API key from Dashboard → Integrations → API, MCP and CLI.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
POST /integrations/invoices-clients — discriminated by client; id present = edit.
POST /integrations/invoices-clients — discriminated by client; id present = edit.
Response Body
application/json
application/json
curl -X POST "https://example.com/integrations/invoices-clients" \ -H "Content-Type: application/json" \ -d '{ "client": "fakturownia", "url": "string", "apiKey": "string", "accountName": "string" }'{ "client": "fakturownia", "id": "string", "url": "string", "createdAt": "string"}{ "error": "string", "message": "string"}Odłącz konto fakturowania
/integrations/invoices-clients/disconnectAuthorization
bearerAuth API key from Dashboard → Integrations → API, MCP and CLI.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
POST /integrations/invoices-clients/disconnect — client + entry id.
Response Body
application/json
application/json
curl -X POST "https://example.com/integrations/invoices-clients/disconnect" \ -H "Content-Type: application/json" \ -d '{ "client": "fakturownia", "id": "string" }'{ "status": "ok"}{ "error": "string", "message": "string"}Połącz bramkę płatności
/integrations/payments/gatewaysAuthorization
bearerAuth API key from Dashboard → Integrations → API, MCP and CLI.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
POST /integrations/payments/gateways — discriminated by gateway; credentials are verified against the gateway first.
POST /integrations/payments/gateways — discriminated by gateway; credentials are verified against the gateway first.
Response Body
application/json
application/json
curl -X POST "https://example.com/integrations/payments/gateways" \ -H "Content-Type: application/json" \ -d '{ "name": "string", "posId": "string", "clientId": "string", "clientSecret": "string", "clientSecondKey": "string", "gateway": "payu" }'{ "stripe": true, "payU": true, "tpay": true, "payNow": true, "przelewy24": true, "paypal": true, "dodo": true, "manual": { "name": "string", "instructions": "string", "updatedAt": "string" }}{ "error": "string", "message": "string"}Odłącz bramkę płatności
/integrations/payments/gateways/disconnectAuthorization
bearerAuth API key from Dashboard → Integrations → API, MCP and CLI.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
POST /integrations/payments/gateways/disconnect.
Response Body
application/json
application/json
curl -X POST "https://example.com/integrations/payments/gateways/disconnect" \ -H "Content-Type: application/json" \ -d '{ "gateway": "payu" }'{ "stripe": true, "payU": true, "tpay": true, "payNow": true, "przelewy24": true, "paypal": true, "dodo": true, "manual": { "name": "string", "instructions": "string", "updatedAt": "string" }}{ "error": "string", "message": "string"}Włącz / wyłącz cykliczny BLIK Tpay
/integrations/payments/tpay/recurring-blikAuthorization
bearerAuth API key from Dashboard → Integrations → API, MCP and CLI.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
PUT /integrations/payments/tpay/recurring-blik.
Response Body
application/json
application/json
curl -X PUT "https://example.com/integrations/payments/tpay/recurring-blik" \ -H "Content-Type: application/json" \ -d '{ "enabled": true }'{ "status": "ok"}{ "error": "string", "message": "string"}Połącz Twilio
/integrations/sms/twilioAuthorization
bearerAuth API key from Dashboard → Integrations → API, MCP and CLI.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
PUT /integrations/sms/twilio — the auth token / API key secret is verified against Twilio first.
Response Body
application/json
application/json
curl -X PUT "https://example.com/integrations/sms/twilio" \ -H "Content-Type: application/json" \ -d '{ "accountSid": "string", "authToken": "string", "senderKind": "messagingService", "sender": "string" }'{ "accountSid": "string", "region": "us1", "authKind": "authToken", "accountName": "string", "senderKind": "messagingService", "sender": "string", "senderLabel": "string"}{ "error": "string", "message": "string"}Odłącz Twilio
/integrations/sms/twilioAuthorization
bearerAuth API key from Dashboard → Integrations → API, MCP and CLI.
In: header
Response Body
application/json
application/json
curl -X DELETE "https://example.com/integrations/sms/twilio"{ "status": "ok"}{ "error": "string", "message": "string"}Połącz SMSAPI
/integrations/sms/smsapiAuthorization
bearerAuth API key from Dashboard → Integrations → API, MCP and CLI.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
PUT /integrations/sms/smsapi — the token is verified against SMSAPI first.
Response Body
application/json
application/json
curl -X PUT "https://example.com/integrations/sms/smsapi" \ -H "Content-Type: application/json" \ -d '{ "region": "pl", "apiToken": "string", "sender": "string" }'{ "region": "pl", "accountName": "string", "sender": "string", "points": 0}{ "error": "string", "message": "string"}Odłącz SMSAPI
/integrations/sms/smsapiAuthorization
bearerAuth API key from Dashboard → Integrations → API, MCP and CLI.
In: header
Response Body
application/json
application/json
curl -X DELETE "https://example.com/integrations/sms/smsapi"{ "status": "ok"}{ "error": "string", "message": "string"}Odśwież nadawców SMSAPI
/integrations/sms/smsapi/refresh-sendersAuthorization
bearerAuth API key from Dashboard → Integrations → API, MCP and CLI.
In: header
Response Body
application/json
application/json
curl -X POST "https://example.com/integrations/sms/smsapi/refresh-senders"{ "senders": [ "string" ], "sender": "string"}{ "error": "string", "message": "string"}Ustaw domyślnego nadawcę SMSAPI
/integrations/sms/smsapi/default-senderAuthorization
bearerAuth API key from Dashboard → Integrations → API, MCP and CLI.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
curl -X PUT "https://example.com/integrations/sms/smsapi/default-sender" \ -H "Content-Type: application/json" \ -d '{ "sender": "string" }'{ "senders": [ "string" ], "sender": "string"}{ "error": "string", "message": "string"}Ustaw domyślnego dostawcę SMS
/integrations/sms/default-providerAuthorization
bearerAuth API key from Dashboard → Integrations → API, MCP and CLI.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Picks which connected provider workflows (and any send without an explicit pick) go through. Only a provider that is connected qualifies.
Response Body
application/json
application/json
curl -X PUT "https://example.com/integrations/sms/default-provider" \ -H "Content-Type: application/json" \ -d '{ "provider": "twilio" }'{ "defaultProvider": "twilio"}{ "error": "string", "message": "string"}Czy ten artykuł był pomocny?

