{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/salesforce-commerce-cloud/json-schema/salesforce-commerce-cloud-client-request-schema.json",
  "title": "ClientRequest",
  "description": "Used to create and update a SLAS Client",
  "x-generated": "2026-11-25",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/salesforce-commerce-cloud-auth-admin-api-openapi.yml#/components/schemas/ClientRequest",
  "required": [
    "channels",
    "clientId",
    "isPrivateClient",
    "name",
    "redirectUri",
    "scopes",
    "secret"
  ],
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "Client Name",
      "maxLength": 100
    },
    "clientId": {
      "type": "string",
      "description": "SLAS client id. Must match the query parameter.",
      "maxLength": 100
    },
    "secret": {
      "type": "string",
      "description": "SLAS client secret. On create if left blank then a secret will be generated.",
      "maxLength": 256
    },
    "scopes": {
      "items": {
        "type": "string",
        "maxLength": 4096
      },
      "type": "array",
      "description": "Merchant scopes. These scopes allows different permissions in SLAS and B2C commerce. \nShopper Custom Objects additionally provides a way to do granular scoping besides the standard `sfcc.shopper-custom-objects` like `sfcc.shopper-custom-objects.xyz` \nSLAS is capable of handling a maximum of 20 Custom Object scopes.\""
    },
    "redirectUri": {
      "items": {
        "type": "string",
        "maxLength": 2048
      },
      "type": "array",
      "description": "Array of SLAS redirect URLs. Include protocol and domain name in each URL. Wildcards supported."
    },
    "callbackUri": {
      "items": {
        "type": "string",
        "maxLength": 2048
      },
      "type": "array",
      "description": "Array of SLAS callback URLs that will be used for passworless login and password reset when mode=callback. Include protocol and domain name in each URL. Wildcards are NOT supported."
    },
    "channels": {
      "items": {
        "type": "string",
        "maxLength": 1024
      },
      "type": "array",
      "description": "Client Channels"
    },
    "isPrivateClient": {
      "type": "boolean",
      "description": "Private or Public Client. If left blank the client will default to private."
    },
    "loginEpRestrict": {
      "type": "boolean",
      "description": "When enabling (true) this will restrict all calls to the `\\login` endpoint for the Client Id. When calling the `\\login` endpoint and `loginEpRestrict` is enabled a HTTP Status code of 403 will be returned."
    },
    "isSixDigitOtp": {
      "type": "boolean",
      "description": "If this attribute is set to true in the request for the clientId, a 6-digit OTP is generated during PasswordlessLogin, PasswordReset, and WebAuthn Authorization. If set to false or unspecified, an 8-digit OTP is generated by default for the aforementioned calls."
    },
    "strictClientAuth": {
      "type": "boolean",
      "description": "When enabled, requests from this client to `/oauth2/login` and `/oauth2/authorize` are rejected with a 401 if the `x-slas-client-auth` header is missing. The `strictClientAuth` attribute applies only to private clients.\nThe 'x-slas-client-auth' header is a Base64-encoded string of client credentials. The string is composed of a client ID and client secret, separated by a colon (`:`). For example, `clientId:clientSecret`. Don't add the string `\"Basic\"`."
    }
  }
}