> ## Documentation Index
> Fetch the complete documentation index at: https://bmpmoneyplus-sandbox.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# 35 - Certification Authority

<Warning>Using the proposal finalization endpoint is mandatory before proceeding.</Warning>

Through this endpoint, the partner executes the proposal signature via Certification Authority. Examples of certification authorities include Docusign, QCertifica, Clicksign, Finanblue, among others.
The signing process begins when the partner downloads the CCB without the "MODEL" watermark from our portal, then signs it through a certification authority, and finally attaches the signed CCB back to the proposal.

<Expandable title="Messaging">
  | Category | Operation               | Action           | Code  | Detailed Code | Message                                                                                          |
  | -------- | ----------------------- | ---------------- | ----- | ------------- | ------------------------------------------------------------------------------------------------ |
  | Proposta | UploadDocumentoProposta | IncluirDocumento | C0068 | V0001         | Informe o nome do arquivo                                                                        |
  | Proposta | UploadDocumentoProposta | IncluirDocumento | C0068 | V0002         | Falha ao enviar Documento                                                                        |
  | Proposta | UploadDocumentoProposta | IncluirDocumento | C0068 | V0003         | Documento não pode ser alterado pois está em processo de análise automática.                     |
  | Proposta | UploadDocumentoProposta | IncluirDocumento | C0112 | V0001         | Proposta não encontrada                                                                          |
  | Proposta | UploadDocumentoProposta | IncluirDocumento | C0112 | V0002         | A Proposta não pertence à esta Integração                                                        |
  | Proposta | UploadDocumentoProposta | IncluirDocumento | C0107 | V0001         | Extensão do arquivo é inválida. Permitido: \[txt,bmp,jpg,jpeg,gif,png,pdf,doc,docx,xls,xlsx,zip] |
  | Proposta | UploadDocumentoProposta | IncluirDocumento | C0107 | V0002         | Tipo de Documento inválido                                                                       |
  | Proposta | UploadDocumentoProposta | IncluirDocumento | C0107 | V0003         | Documento deve ser enviado                                                                       |
  | Proposta | UploadDocumentoProposta | IncluirDocumento | C0020 | V0001         | Extensão do arquivo é inválida. Permitido: \[{GRANTTYPES}]                                       |
  | Proposta | UploadDocumentoProposta | IncluirDocumento | T0665 | D0001         | Informe o Cliente                                                                                |
  | Proposta | UploadDocumentoProposta | IncluirDocumento | T0665 | D0002         | Documento do Cliente é inválido                                                                  |
  | Proposta | UploadDocumentoProposta | IncluirDocumento | T0665 | D0016         | EPCodigo não informado                                                                           |
  | Proposta | UploadDocumentoProposta | IncluirDocumento | T0665 | D0017         | Vendedor não encontrado                                                                          |
  | Proposta | UploadDocumentoProposta | IncluirDocumento | T0665 | D0018         | Promotor não encontrado                                                                          |
  | Proposta | UploadDocumentoProposta | IncluirDocumento | T0665 | D0019         | Informe o Tipo de Operação                                                                       |
  | Proposta | UploadDocumentoProposta | IncluirDocumento | T0665 | D0020         | Informe o Valor                                                                                  |
  | Proposta | UploadDocumentoProposta | IncluirDocumento | T0665 | D0021         | Informe a Quantidade de Parcelas                                                                 |
  | Proposta | UploadDocumentoProposta | IncluirDocumento | T0665 | D0022         | Formato de cálculo inválido                                                                      |
  | Proposta | UploadDocumentoProposta | IncluirDocumento | T0665 | D0023         | Cliente deve ser pessoa física                                                                   |
</Expandable>


## OpenAPI

````yaml post /Proposta/IncluirDocumento
openapi: 3.0.1
info:
  title: BMPDigitalCore.ApiExterna.Proposta.API
  version: '1.0'
servers:
  - url: https://api.bmpdigital.moneyp.dev.br/
    description: Localhost
security:
  - Bearer: []
paths:
  /Proposta/IncluirDocumento:
    post:
      tags:
        - Proposta
      parameters:
        - name: IdempotencyKey
          in: header
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UploadDocumentoPropostaCommand'
          text/json:
            schema:
              $ref: '#/components/schemas/UploadDocumentoPropostaCommand'
          application/*+json:
            schema:
              $ref: '#/components/schemas/UploadDocumentoPropostaCommand'
      responses:
        '200':
          description: OK
          content:
            text/plain:
              schema:
                $ref: '#/components/schemas/UploadDocumentResponse'
            application/json:
              schema:
                $ref: '#/components/schemas/UploadDocumentResponse'
            text/json:
              schema:
                $ref: '#/components/schemas/UploadDocumentResponse'
        '400':
          description: Bad Request
          content:
            text/plain:
              schema:
                $ref: '#/components/schemas/ResponseBase'
            application/json:
              schema:
                $ref: '#/components/schemas/ResponseBase'
            text/json:
              schema:
                $ref: '#/components/schemas/ResponseBase'
components:
  schemas:
    UploadDocumentoPropostaCommand:
      type: object
      properties:
        dto:
          $ref: '#/components/schemas/FindPropostaDTO'
        documento:
          $ref: '#/components/schemas/UploadDocumentDTO'
      additionalProperties: false
    UploadDocumentResponse:
      type: object
      properties:
        msg:
          type: string
          nullable: true
        result:
          type: boolean
          writeOnly: true
        hasError:
          type: boolean
        messages:
          type: array
          items:
            $ref: '#/components/schemas/Message'
          nullable: true
        codigo:
          type: string
          format: uuid
          nullable: true
        tipoDocumento:
          type: integer
          format: int32
        nomeArquivo:
          type: string
          nullable: true
        extensao:
          type: string
          nullable: true
        dtValidade:
          type: string
          format: date-time
          nullable: true
        arquivo:
          type: string
          format: byte
          nullable: true
      additionalProperties: false
    ResponseBase:
      type: object
      properties:
        msg:
          type: string
          nullable: true
        result:
          type: boolean
          writeOnly: true
        hasError:
          type: boolean
        messages:
          type: array
          items:
            $ref: '#/components/schemas/Message'
          nullable: true
      additionalProperties: false
    FindPropostaDTO:
      type: object
      properties:
        codigoProposta:
          type: string
          description: Código identificador da proposta
          format: uuid
          nullable: true
        codigoOperacao:
          type: string
          description: Código da operação do parceiro
          nullable: true
        numeroProposta:
          type: integer
          description: Número sequencial da proposta
          format: int64
          nullable: true
      additionalProperties: false
    UploadDocumentDTO:
      required:
        - extensao
        - nomeArquivo
        - tipoDocumento
      type: object
      properties:
        codigo:
          type: string
          description: Preenchido com o código do arquivo na base BMP
          format: uuid
        tipoDocumento:
          type: integer
          description: Consultar tabela de tipo de documento
          format: int32
        nomeArquivo:
          maxLength: 255
          minLength: 0
          type: string
          description: Nome do arquivo
          nullable: true
        extensao:
          maxLength: 20
          minLength: 0
          type: string
          description: Extensão do arquivo
          nullable: true
        dtValidade:
          type: string
          description: Data de Validade do Arquivo
          format: date-time
          nullable: true
        arquivo:
          type: string
          description: Array de bytes que contém o arquivo
          format: byte
          nullable: true
      additionalProperties: false
    Message:
      type: object
      properties:
        messageType:
          $ref: '#/components/schemas/ErrorType'
        code:
          type: string
          nullable: true
        context:
          type: string
          nullable: true
        description:
          type: string
          nullable: true
        field:
          type: string
          nullable: true
      additionalProperties: false
    ErrorType:
      enum:
        - 1
        - 2
        - 3
      type: integer
      format: int32
  securitySchemes:
    Bearer:
      type: apiKey
      description: Informe o token
      name: Authorization
      in: header

````