Didomi consents/proofs API

The consents/proofs API from Didomi — 2 operation(s) for consents/proofs.

Documentation

Specifications

Schemas & Data

Other Resources

OpenAPI Specification

didomi-consents-proofs-api-openapi.yml Raw ↑
openapi: 3.0.2
info:
  title: Didomi consents/events consents/proofs API
  description: 'A REST API to communicate with the Didomi platform (<a href="https://api.didomi.io/v1/">https://api.didomi.io/v1/</a>)


    This is the complete specification of the API. A complete guide to authenticating and using the API is available on our <a href="https://developers.didomi.io/" target="_blank">Developers Portal</a>.


    All HTTP calls to the API require a valid JWT token. The token must be provided in an **Authorization** header with the value "Bearer <token>".

    Click on the Authorize button in the header of this page to provide a token before testing requests from this documentation.


    '
  version: '1.0'
servers:
- url: https://api.didomi.io/v1
  description: Didomi Platform API
security:
- bearer: []
tags:
- name: consents/proofs
paths:
  /consents/proofs:
    post:
      summary: Upload a consent proof
      description: Upload a file to serve as proof of consent
      parameters:
      - name: organization_id
        in: query
        description: The ID of the organization that the proof belongs to
        required: true
        schema:
          type: string
      - name: file
        in: body
        description: Proof information
        required: true
        schema:
          $ref: '#/definitions/consent-proofs-input'
      responses:
        '200':
          description: The created ConsentProof object
          content:
            application/json:
              schema:
                $ref: '#/definitions/consent-proofs'
      tags:
      - consents/proofs
      consumes:
      - application/json
      produces:
      - application/json
      security:
      - bearer: []
  /consents/proofs/{id}:
    get:
      summary: Retrieve a proof
      description: Returns a consent proof
      security:
      - bearer: []
      parameters:
      - name: id
        in: path
        description: Unique ID of the proof to retrieve
        required: true
        schema:
          type: string
      - name: organization_id
        in: query
        description: The ID of the organization that the proof belongs to
        required: true
        schema:
          type: string
      responses:
        '200':
          description: A ConsentProof object
          content:
            application/json:
              schema:
                $ref: '#/definitions/consent-proofs'
      tags:
      - consents/proofs
      consumes:
      - application/json
      produces:
      - application/json
components:
  securitySchemes:
    bearer:
      scheme: bearer
      bearerFormat: JWT
      type: http
definitions:
  consent-proofs:
    type: object
    title: ConsentProof
    description: A file proving the consent of the user
    properties:
      id:
        type: string
        description: Unique ID of the proof
      size:
        type: integer
        description: Size of the proof in bytes
      file:
        type: string
        description: Base64-encoded data URI
    required:
    - id
    - size
    - file
  consent-proofs-input:
    type: object
    title: ConsentProof
    description: A file proving the consent of the user
    properties:
      file:
        type: string
        description: 'Base64-encoded data URI. Accepted file formats: PDF, PNG, JPG, GIF, DOCX, DOC'
    required:
    - file