> ## 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.

# Criar uma configuração de fonte de entrada

> Provisiona uma configuração de fonte de entrada para o tenant autenticado. Cada configuração é protegida contra a reserva de descoberta de entrada configurada antes da persistência; uma violação resulta em 422 POLLING_BUDGET_EXCEEDED.



## OpenAPI

````yaml pt/openapi/v3-current/sta.yaml post /v1/inbound-source-configs
openapi: 3.0.3
info:
  title: Lerian STA API
  description: >-
    API do Lerian STA — o rail do lado do participante que conecta a instituição
    ao sistema de troca de arquivos STA (Sistema de Transferência de Arquivos)
    do Banco Central do Brasil. Abrange as transferências de arquivos de saída e
    de entrada, a gestão de credenciais do BACEN, a configuração da sondagem de
    fontes de entrada e o trust-store do tenant para os certificados de
    assinatura de mensagens.
  version: v1.0.0
servers:
  - url: https://sta.sandbox.lerian.net
security:
  - BearerAuth: []
tags:
  - name: transfers
    description: >-
      Transferências de arquivos STA de saída e de entrada — criação, listagem,
      leitura, cancelamento, nova tentativa e marcação de processamento urgente.
  - name: trust-store
    description: >-
      Ciclo de vida dos certificados X.509 do trust-store do tenant: listagem,
      upload, exclusão e resumo de status.
  - name: credentials
    description: >-
      Gestão de credenciais do BACEN STA: criação, leitura, atualização,
      rotação, revogação e teste de conectividade.
  - name: inbound-source-configs
    description: >-
      Configuração da sondagem de fontes de entrada: criação, leitura,
      atualização, exclusão, disparo manual de sondagem e uso da reserva de
      descoberta.
  - name: health
    description: Relatório de saúde e prontidão do serviço.
paths:
  /v1/inbound-source-configs:
    post:
      tags:
        - inbound-source-configs
      summary: Criar uma configuração de fonte de entrada
      description: >-
        Provisiona uma configuração de fonte de entrada para o tenant
        autenticado. Cada configuração é protegida contra a reserva de
        descoberta de entrada configurada antes da persistência; uma violação
        resulta em 422 POLLING_BUDGET_EXCEEDED.
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/http.CreateInboundSourceConfigRequest'
        description: inbound source config payload
        required: true
      responses:
        '201':
          description: Created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/http.InboundSourceConfigView'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                additionalProperties: true
                type: object
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                additionalProperties: true
                type: object
        '409':
          description: Conflict
          content:
            application/json:
              schema:
                additionalProperties: true
                type: object
        '422':
          description: Unprocessable Entity
          content:
            application/json:
              schema:
                additionalProperties: true
                type: object
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                additionalProperties: true
                type: object
components:
  schemas:
    http.CreateInboundSourceConfigRequest:
      properties:
        bacenSystemCode:
          type: string
        bacenSystemFilterCode:
          type: string
        credentialId:
          description: >-
            CredentialID is the UUID of the BACEN credential used to fetch
            inbound

            documents of this source. MANDATORY: every inbound source fetches
            with a

            credential. The uuid tag rejects a malformed value at the boundary
            (400);

            the domain constructor rejects uuid.Nil (422 via the
            reserve/invariant

            path).
          type: string
        displayName:
          type: string
        intervalSeconds:
          maximum: 1800
          minimum: 15
          type: integer
        maxFileSizeBytes:
          minimum: 1
          type: integer
        retentionDays:
          maximum: 3650
          minimum: 1
          type: integer
        sourceProduct:
          type: string
        urgencyEnabled:
          description: >-
            UrgencyEnabled opts this inbound source into urgent inbound
            processing.

            Defaults false. Operator-settable.
          type: boolean
      required:
        - bacenSystemCode
        - credentialId
        - intervalSeconds
        - sourceProduct
      type: object
    http.InboundSourceConfigView:
      properties:
        bacenSystemCode:
          type: string
        bacenSystemFilterCode:
          type: string
        createdAt:
          type: string
        credentialId:
          description: >-
            CredentialID is the UUID string of the BACEN credential bound to
            this

            inbound source (mandatory and always present).
          type: string
        deletedAt:
          type: string
        displayName:
          type: string
        id:
          type: string
        intervalSeconds:
          type: integer
        isEnabled:
          type: boolean
        maxFileSizeBytes:
          type: integer
        retentionDays:
          type: integer
        sourceProduct:
          type: string
        updatedAt:
          type: string
        urgencyEnabled:
          type: boolean
      type: object
  securitySchemes:
    BearerAuth:
      description: 'Bearer token authentication (format: "Bearer {token}")'
      in: header
      name: Authorization
      type: apiKey

````