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

# Create a settlement operation

> Submits a single settlement operation for intake. Idempotent via the Idempotency-Key header.



## OpenAPI

````yaml en/openapi/v3-current/slc.yaml post /v1/operations
openapi: 3.0.3
info:
  title: Lerian SLC API
  description: >-
    API for Lerian SLC — the participant-side rail that connects the institution
    to Núclea's SLC deferred-net card settlement. It covers settlement-operation
    intake and lifecycle, clearing positions, the participant and arrangement
    registry, transmission recovery and connectivity to Núclea, BYOK Model-A
    signing-key import, and tenant-scoped webhooks.
  version: v1.0.0
servers:
  - url: https://slc.sandbox.lerian.net
security: []
tags:
  - name: Admin
    description: Tenant configuration and dead-letter administration.
  - name: Clearing
    description: Deferred-net clearing positions for the settlement institution.
  - name: Connectivity
    description: >-
      Transmission recovery drains, retransmission, and connectivity probes to
      Núclea.
  - name: Operations
    description: Settlement operation intake, lifecycle, and state history.
  - name: Participants
    description: Participant registry for the tenant.
  - name: Arrangements
    description: Card and scheme arrangements per participant.
  - name: SigningKey
    description: BYOK Model-A signing-key import for message signing.
  - name: Webhooks
    description: Tenant-scoped webhook subscriptions, deliveries, and replay.
paths:
  /v1/operations:
    post:
      tags:
        - Operations
      summary: Create a settlement operation
      description: >-
        Submits a single settlement operation for intake. Idempotent via the
        Idempotency-Key header.
      operationId: createOperation
      parameters:
        - description: Idempotency key for safe retries
          in: header
          name: Idempotency-Key
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/http.CreateOperationRequest'
        description: Operation to create
        required: true
      responses:
        '202':
          description: Accepted
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/http.CreateOperationResponse'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/http.ErrorResponse'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/http.ErrorResponse'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/http.ErrorResponse'
        '409':
          description: Conflict
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/http.ErrorResponse'
        '422':
          description: Unprocessable Entity
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/http.ErrorResponse'
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/http.ErrorResponse'
      security:
        - BearerAuth: []
components:
  schemas:
    http.CreateOperationRequest:
      properties:
        arrangementCode:
          type: string
        authorizationCode:
          type: string
        brandCode:
          type: string
        creditorIspb:
          type: string
        currency:
          type: string
        domicileIfIspb:
          type: string
        dueDate:
          type: string
        establishmentCode:
          type: string
        externalId:
          type: string
        installmentNumber:
          type: integer
        installments:
          type: integer
        intakeMode:
          type: string
        metadata:
          additionalProperties: {}
          type: object
        operationType:
          type: string
        originalOperationId:
          description: >-
            OriginalOperationID identifies the operation a CANCELLATION targets
            (UUID).

            Mandatory for operationType=CANCELLATION, ignored otherwise.
          type: string
        participantId:
          type: string
        participantRole:
          type: string
        pvCode:
          description: >-
            PontoVenda (merchant/EC) identity for the ASLC027
            Grupo_ASLC027_PontoVenda.

            Required for CREDIT, enforced in the command use case (not via
            struct tags),

            because only CREDIT mandates the [1..1] PontoVenda identity.
            pvDocument is

            the merchant CPF/CNPJ — regulated PII; it is never logged in the
            clear.
          type: string
        pvDocument:
          type: string
        pvName:
          type: string
        pvPersonType:
          type: string
        reasonCategory:
          description: >-
            ReasonCategory is the numeric <MotvCanc> cancellation reason (OP107
            §11.3.16),

            one of "1".."4". Mandatory for operationType=CANCELLATION, optional
            otherwise.

            Carried as a string on the wire so the nullable-text column and the
            value

            object stay symmetric; the 1..4 domain is enforced by the domain,
            not the XSD.
          type: string
        settlementIfIspb:
          type: string
        transactionDate:
          type: string
        value:
          type: integer
      required:
        - creditorIspb
        - domicileIfIspb
        - dueDate
        - externalId
        - installments
        - operationType
        - participantId
        - participantRole
        - value
      type: object
    http.CreateOperationResponse:
      properties:
        externalId:
          type: string
        id:
          type: string
        meta:
          $ref: '#/components/schemas/http.CreateOperationMeta'
        state:
          type: string
      type: object
    http.ErrorResponse:
      properties:
        code:
          type: string
        details:
          additionalProperties: {}
          type: object
        message:
          type: string
        title:
          type: string
      type: object
    http.CreateOperationMeta:
      properties:
        requestId:
          type: string
        timestamp:
          type: string
      type: object
  securitySchemes:
    BearerAuth:
      description: 'Bearer token authentication (format: "Bearer {token}")'
      in: header
      name: Authorization
      type: apiKey

````