> ## Documentation Index
> Fetch the complete documentation index at: https://docs.dataspike.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Create a KYB flow-profile (dashboard)

> Dashboard-facing twin of POST /api/v4/kyb-profiles: creates a KYB flow-profile binding a KYC verification profile (kyc_profile_id, must belong to the org) and the submit gate (allow_submit_on_failed_kyc) to an optional role (production/dashboard, or empty for user-defined). One production and one dashboard per org (duplicate → 409). Org comes from the path; the web session must belong to it.



## OpenAPI

````yaml https://api.dataspike.io/openapi/kyb/public.json post /webapi/v4/kyb/organization/{organizationId}/kyb-profiles
openapi: 3.1.0
info:
  description: Know Your Business (KYB) — case creation and the embedded onboarding widget.
  title: Dataspike KYB API
  version: '1.0'
servers: []
security: []
paths:
  /webapi/v4/kyb/organization/{organizationId}/kyb-profiles:
    post:
      tags:
        - KYB Profiles
      summary: Create a KYB flow-profile (dashboard)
      description: >-
        Dashboard-facing twin of POST /api/v4/kyb-profiles: creates a KYB
        flow-profile binding a KYC verification profile (kyc_profile_id, must
        belong to the org) and the submit gate (allow_submit_on_failed_kyc) to
        an optional role (production/dashboard, or empty for user-defined). One
        production and one dashboard per org (duplicate → 409). Org comes from
        the path; the web session must belong to it.
      operationId: POST_/webapi/v4/kyb/organization/:organizationId/kyb-profiles
      parameters:
        - description: Organization id.
          in: path
          name: organizationId
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateKybProfileRequest'
          application/xml:
            schema:
              $ref: '#/components/schemas/CreateKybProfileRequest'
        description: Request body for kyb.CreateKybProfileRequest
        required: true
      responses:
        '201':
          content:
            application/json:
              schema:
                $ref: d5293a33-1d10-4aa2-8ff9-4a2c9a2d1e19
            application/xml:
              schema:
                $ref: d5293a33-1d10-4aa2-8ff9-4a2c9a2d1e19
          description: Created
        '400':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrInvalidBody'
            application/xml:
              schema:
                $ref: '#/components/schemas/ErrInvalidBody'
          description: Invalid body, role, or kyc_profile_id.
        '409':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrKybProfileRoleExists'
            application/xml:
              schema:
                $ref: '#/components/schemas/ErrKybProfileRoleExists'
          description: A profile with this role already exists for the org.
        '422':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrKycProfileNotFound'
            application/xml:
              schema:
                $ref: '#/components/schemas/ErrKycProfileNotFound'
          description: kyc_profile_id does not reference a profile in this org.
        default:
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CreateKybProfileResponse'
            application/xml:
              schema:
                $ref: '#/components/schemas/CreateKybProfileResponse'
          description: KYB profile created.
      security:
        - Session: []
components:
  schemas:
    CreateKybProfileRequest:
      description: CreateKybProfileRequest schema
      properties:
        allow_submit_on_failed_kyc:
          example: false
          type: boolean
        kyc_profile_id:
          example: 0195c1f0-1234-7000-8000-0123456789ab
          type: string
        name:
          example: Production (external clients)
          nullable: true
          type: string
        role:
          example: production
          nullable: true
          type: string
      type: object
    ErrInvalidBody:
      description: ErrInvalidBody schema
      example:
        code: invalid_body
        message: Invalid request body
      properties:
        code:
          example: email_otp_expired
          type: string
        message:
          example: OTP has expired
          type: string
        param:
          nullable: true
          type: string
      type: object
    ErrKybProfileRoleExists:
      description: ErrKybProfileRoleExists schema
      example:
        code: kyb_profile_role_exists
        message: a KYB profile with this role already exists for the organization
      properties:
        code:
          example: email_otp_expired
          type: string
        message:
          example: OTP has expired
          type: string
        param:
          nullable: true
          type: string
      type: object
    ErrKycProfileNotFound:
      description: ErrKycProfileNotFound schema
      example:
        code: kyc_profile_not_found
        message: kyc_profile_id does not reference an existing verification profile
      properties:
        code:
          example: email_otp_expired
          type: string
        message:
          example: OTP has expired
          type: string
        param:
          nullable: true
          type: string
      type: object
    CreateKybProfileResponse:
      description: CreateKybProfileResponse schema
      properties:
        allow_submit_on_failed_kyc:
          example: false
          type: boolean
        kyb_profile_id:
          example: 0195c1f0-1234-7000-8000-0123456789ab
          type: string
        kyc_profile_id:
          example: 0195c1f0-1234-7000-8000-0123456789ab
          type: string
        name:
          example: Production (external clients)
          nullable: true
          type: string
        role:
          example: production
          nullable: true
          type: string
      type: object
  securitySchemes:
    Session:
      description: Session cookie for web dashboard authentication.
      in: cookie
      name: ds-prod-session
      type: apiKey

````