Cognis
Commerce Settings

Put

PUT
/org/{orgId}/ecom

Partial-friendly PUT fields: storefront currency pair (mainCurrency + enabledStorefrontCurrencies) must be supplied together — omit both to preserve existing presets. Omitting Stripe / checkout overrides leaves those columns untouched. Order numbering fields (orderNumberPrefix, orderNumberSeparator, orderNumberPadding, orderNumberStartingMinimum) configure how Cognis formats commerce_orders.order_number for new storefront orders; each is independently optional and any subset sent must form a valid configuration when merged with the existing column values.

Required scopes: org:ecom:settings:write, org:ecom:checkout:write

Authorization

bearerAuth
AuthorizationBearer <token>

API key (prefix: cogn_) from Account → Developer

In: header

Path Parameters

orgId*string

Organization ID (prefix: org_)

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X PUT "http://localhost:3013/api/v1/org/string/ecom" \  -H "Content-Type: application/json" \  -d '{}'
{
  "success": true,
  "data": {
    "id": "1",
    "activeLangs": [
      "en",
      "sv"
    ],
    "primaryLang": "en",
    "defaultStripeIntegrationId": null,
    "defaultAirwallexIntegrationId": null,
    "defaultPorkbunIntegrationId": null,
    "checkoutProvider": "stripe_hosted",
    "mainCurrency": "USD",
    "enabledStorefrontCurrencies": [
      "USD",
      "EUR",
      "SEK"
    ],
    "activeLangsUnion": [
      "en",
      "sv"
    ],
    "secondaryLangsForTranslationOps": [
      "sv"
    ],
    "orderNumberPrefix": null,
    "orderNumberSeparator": "",
    "orderNumberPadding": 4,
    "orderNumberStartingMinimum": 1,
    "taxPriceMode": "exclusive",
    "taxMode": "disabled",
    "defaultTaxCode": null,
    "defaultExemptTaxCode": null,
    "catalogSource": "cognis",
    "discountStackingPolicy": "single_best",
    "cognisDiscountEngineEnabled": false,
    "allowStripeNativePromotionCodes": true,
    "wishlistEnabled": true,
    "wishlistMaxItems": null,
    "productDiscoveryDefaults": null,
    "skuPrefix": null,
    "defaultImportInitialOnHand": null,
    "abandonedCheckoutConfig": {
      "enabled": true,
      "steps": [
        {
          "delayMinutes": 60,
          "enabled": true
        },
        {
          "delayMinutes": 1440,
          "enabled": true
        },
        {
          "delayMinutes": 4320,
          "enabled": true
        }
      ]
    },
    "klaviyoCheckoutEventsConfig": {
      "enabled": false,
      "klaviyoIntegrationId": null,
      "suppressCognisAbandonedEmails": true
    }
  },
  "message": "Success",
  "traceId": "req_abc123"
}
{
  "success": false,
  "message": "Invalid data",
  "errors": [
    {
      "code": 400,
      "message": "Invalid data"
    }
  ],
  "traceId": "req_xxx"
}
{
  "success": false,
  "message": "Unauthorized",
  "errors": [
    {
      "code": 401,
      "message": "Unauthorized"
    }
  ],
  "traceId": "req_xxx"
}
{
  "success": false,
  "message": "Forbidden",
  "errors": [
    {
      "code": 403,
      "message": "Forbidden"
    }
  ],
  "traceId": "req_xxx"
}
{
  "success": false,
  "message": "Not found",
  "errors": [
    {
      "code": 404,
      "message": "Not found"
    }
  ],
  "traceId": "req_xxx"
}
{
  "success": false,
  "message": "Conflict",
  "errors": [
    {
      "code": 409,
      "message": "Conflict"
    }
  ],
  "traceId": "req_xxx"
}
{
  "success": false,
  "message": "string",
  "errors": [
    {
      "code": 0,
      "message": "string",
      "details": {}
    }
  ],
  "traceId": "string",
  "params": {},
  "readableMessage": "string"
}
{
  "success": false,
  "message": "Rate limit exceeded",
  "errors": [],
  "traceId": "req_xxx"
}
{
  "success": false,
  "message": "Unexpected error",
  "errors": [
    {
      "code": 500,
      "message": "Unexpected error"
    }
  ],
  "traceId": "req_xxx"
}