openapi: 3.0.0
info:
  title: Zigned REST API
  version: 3.0.0
paths:
  /agreements:
    get:
      operationId: GetAgreements
      responses:
        "200":
          description: GET /agreements Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - paginated_list
                    description: A paginated list of the agreement resource.
                  resource_type:
                    type: string
                    enum:
                      - agreement
                    description: Data contains the agreement resource.
                  data:
                    type: array
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                          format: cuid
                          description: The unique identifier of the agreement
                          example: cckmmstwimwnfgqvuajexample
                        resource_type:
                          type: string
                          enum:
                            - agreement
                        test_mode:
                          type: boolean
                          description: Indicates if the agreement is created using a development client
                        status:
                          type: string
                          enum:
                            - draft
                            - pending
                            - fulfilled
                            - cancelled
                            - generating
                            - failed_to_generate
                            - open
                            - expired
                          description: The status of the agreement
                        trust_level:
                          type: string
                          enum:
                            - SES
                            - AES
                            - QES
                          description: The minimum trust level  for the signatures.
                        cancellation_reason:
                          nullable: true
                          type: string
                          description: If the agreement is in a cancelled state, this will be a short
                            description on the reason why, otherwise it will be
                            null.
                          example: null
                        theme:
                          oneOf:
                            - type: string
                              format: cuid
                              description: The unique identifier for the theme attached to the agreement
                              example: ccrirlws7dyjk2rzo2aexample
                            - type: object
                              properties:
                                version:
                                  type: string
                                  enum:
                                    - "1.0"
                                  description: The version of the response schema
                                result_type:
                                  type: string
                                  enum:
                                    - single
                                  description: A single object of the theme resource.
                                resource_type:
                                  type: string
                                  enum:
                                    - theme
                                  description: Data contains the theme resource.
                                data:
                                  type: object
                                  properties:
                                    id:
                                      type: string
                                      format: cuid
                                      description: The unique identifier of the theme
                                      example: coerir2amisfebqzdooexample
                                    resource_type:
                                      type: string
                                      enum:
                                        - theme
                                    logo:
                                      type: object
                                      properties:
                                        version:
                                          type: string
                                          enum:
                                            - "1.0"
                                          description: The version of the response schema
                                        result_type:
                                          type: string
                                          enum:
                                            - single
                                          description: A single object of the file resource.
                                        resource_type:
                                          type: string
                                          enum:
                                            - file
                                          description: Data contains the file resource.
                                        data:
                                          type: object
                                          properties:
                                            id:
                                              type: string
                                              format: cuid
                                              description: The unique identifier of the file
                                              example: cytp5m6ijs4rxs0erqsexample
                                            resource_type:
                                              type: string
                                              enum:
                                                - file
                                            filename:
                                              type: string
                                              minLength: 1
                                              description: The complete filename including the file extension
                                              example: my-file.pdf
                                            mime_type:
                                              type: string
                                              minLength: 1
                                              description: The mime type of the file
                                              example: application/pdf
                                            url:
                                              type: string
                                              format: url
                                              description: The signed read url of the file
                                              example: https://zigned.se
                                            metadata:
                                              type: object
                                              properties:
                                                lookup_key:
                                                  type: string
                                                  description: A provided lookup key provided by you to help you identify the
                                                    file.
                                                  example: file_tag
                                              required:
                                                - lookup_key
                                            created_at:
                                              type: string
                                              description: UTC datetime ISO string
                                              example: 2024-01-01T00:00:00.000Z
                                            updated_at:
                                              type: string
                                              description: UTC datetime ISO string
                                              example: 2024-01-01T00:00:00.000Z
                                          required:
                                            - id
                                            - resource_type
                                            - filename
                                            - mime_type
                                            - created_at
                                            - updated_at
                                          description: The resource data.
                                      required:
                                        - version
                                        - result_type
                                        - resource_type
                                        - data
                                      description: The logo of the theme. This is displayed to the user in all
                                        communication and touch points.
                                    icon:
                                      type: object
                                      properties:
                                        version:
                                          type: string
                                          enum:
                                            - "1.0"
                                          description: The version of the response schema
                                        result_type:
                                          type: string
                                          enum:
                                            - single
                                          description: A single object of the file resource.
                                        resource_type:
                                          type: string
                                          enum:
                                            - file
                                          description: Data contains the file resource.
                                        data:
                                          type: object
                                          properties:
                                            id:
                                              type: string
                                              format: cuid
                                              description: The unique identifier of the file
                                              example: cytp5m6ijs4rxs0erqsexample
                                            resource_type:
                                              type: string
                                              enum:
                                                - file
                                            filename:
                                              type: string
                                              minLength: 1
                                              description: The complete filename including the file extension
                                              example: my-file.pdf
                                            mime_type:
                                              type: string
                                              minLength: 1
                                              description: The mime type of the file
                                              example: application/pdf
                                            url:
                                              type: string
                                              format: url
                                              description: The signed read url of the file
                                              example: https://zigned.se
                                            metadata:
                                              type: object
                                              properties:
                                                lookup_key:
                                                  type: string
                                                  description: A provided lookup key provided by you to help you identify the
                                                    file.
                                                  example: file_tag
                                              required:
                                                - lookup_key
                                            created_at:
                                              type: string
                                              description: UTC datetime ISO string
                                              example: 2024-01-01T00:00:00.000Z
                                            updated_at:
                                              type: string
                                              description: UTC datetime ISO string
                                              example: 2024-01-01T00:00:00.000Z
                                          required:
                                            - id
                                            - resource_type
                                            - filename
                                            - mime_type
                                            - created_at
                                            - updated_at
                                          description: The resource data.
                                      required:
                                        - version
                                        - result_type
                                        - resource_type
                                        - data
                                      description: The icon of the theme. This is used for the favicon.
                                    primary_color:
                                      type: string
                                      default: "#000000"
                                      description: The primary color used to create the color palette in the signing
                                        room.
                                      example: "#000000"
                                    metadata:
                                      type: object
                                      properties:
                                        lookup_key:
                                          type: string
                                          description: A provided lookup key provided by you to help you identify the
                                            theme.
                                          example: your_internal_customer_id
                                      required:
                                        - lookup_key
                                    created_at:
                                      type: string
                                      description: UTC datetime ISO string
                                      example: 2024-01-01T00:00:00.000Z
                                    updated_at:
                                      type: string
                                      description: UTC datetime ISO string
                                      example: 2024-01-01T00:00:00.000Z
                                  required:
                                    - id
                                    - resource_type
                                    - logo
                                    - icon
                                    - created_at
                                    - updated_at
                                  description: The resource data.
                              required:
                                - version
                                - result_type
                                - resource_type
                                - data
                            - type: string
                              nullable: true
                              format: "null"
                        issuer:
                          type: object
                          properties:
                            name:
                              nullable: true
                              type: string
                              description: The name of the issuer. Required if no email is provided.
                              example: John Doe
                            email:
                              nullable: true
                              type: string
                              description: The email of the issuer. Required if agreemnt is configured to send
                                emails.
                              example: example@example.com
                            role:
                              type: string
                              enum:
                                - signer
                                - approver
                                - observer
                              description: The role of the issuer in the agreement process.
                            participant_id:
                              type: string
                              format: cuid
                              description: If the issuer is a signer or approver this is the ID of the related
                                participant.
                              example: cd0jga4zijaebyga1wlexample
                            signing_room_url:
                              nullable: true
                              type: string
                              format: url
                              example: https://www.zigned.se/sign/cjecfacxrxzqd9def5zexample/cmakdfl6yfb9ls8h6jyexample
                              description: The URL to the signing room for the issuer. Only available after
                                the agreement has been finalized for signing.
                            locale:
                              nullable: true
                              type: string
                              enum:
                                - sv-SE
                                - en-US
                              description: The locale for the issuer. Can be overridden from the signing room,
                                but this value serves as the default if nothing
                                else is specified. If omitted, the
                                default_locale of the agreement is used.
                          required:
                            - name
                            - email
                            - role
                            - signing_room_url
                          description: The issuer of the agreement
                        participants:
                          oneOf:
                            - type: array
                              items:
                                type: string
                                format: cuid
                                minLength: 1
                              description: List of all IDs for the participants belonging to this agreement
                              example:
                                - c5lnvzb9saw7pkusnvcexample
                                - cgizx0nvpnyzxupx0cvexample
                                - codqlu3eiigxia664m3example
                            - type: object
                              properties:
                                version:
                                  type: string
                                  enum:
                                    - "1.0"
                                  description: The version of the response schema
                                result_type:
                                  type: string
                                  enum:
                                    - list
                                  description: A non-paginated list of the participant resource.
                                resource_type:
                                  type: string
                                  enum:
                                    - participant
                                  description: Data contains the participant resource.
                                data:
                                  $ref: "#/components/schemas/95c1af3f45da65daeedb661f70210b46b2bd71d5"
                              required:
                                - version
                                - result_type
                                - resource_type
                                - data
                            - type: string
                              nullable: true
                              format: "null"
                        observers:
                          oneOf:
                            - type: array
                              items:
                                type: string
                                format: cuid
                                minLength: 1
                              description: List of all IDs for the observers belonging to this agreement
                              example:
                                - c5lnvzb9saw7pkusnvcexample
                                - cgizx0nvpnyzxupx0cvexample
                                - codqlu3eiigxia664m3example
                            - type: object
                              properties:
                                version:
                                  type: string
                                  enum:
                                    - "1.0"
                                  description: The version of the response schema
                                result_type:
                                  type: string
                                  enum:
                                    - list
                                  description: A non-paginated list of the observer resource.
                                resource_type:
                                  type: string
                                  enum:
                                    - observer
                                  description: Data contains the observer resource.
                                data:
                                  $ref: "#/components/schemas/c893c5c1d97a5bcbd8972ce188f48f8f75c6a171"
                              required:
                                - version
                                - result_type
                                - resource_type
                                - data
                            - type: string
                              nullable: true
                              format: "null"
                        signing_groups:
                          oneOf:
                            - type: array
                              items:
                                type: string
                                format: cuid
                                minLength: 1
                              description: List of all IDs for the signing groups belonging to this agreement
                              example:
                                - c5lnvzb9saw7pkusnvcexample
                                - cgizx0nvpnyzxupx0cvexample
                                - codqlu3eiigxia664m3example
                            - type: object
                              properties:
                                version:
                                  type: string
                                  enum:
                                    - "1.0"
                                  description: The version of the response schema
                                result_type:
                                  type: string
                                  enum:
                                    - list
                                  description: A non-paginated list of the signing group resource.
                                resource_type:
                                  type: string
                                  enum:
                                    - signing_group
                                  description: Data contains the signing group resource.
                                data:
                                  $ref: "#/components/schemas/d69cfbd1e408327b80080ee78c087563df3370f4"
                              required:
                                - version
                                - result_type
                                - resource_type
                                - data
                            - type: string
                              nullable: true
                              format: "null"
                        documents:
                          type: object
                          properties:
                            original_documents:
                              type: object
                              properties:
                                main:
                                  oneOf:
                                    - type: string
                                      format: cuid
                                      description: The unique identifier of the main document
                                      example: cmwqhs06osj0tus71kcexample
                                    - type: object
                                      properties:
                                        version:
                                          type: string
                                          enum:
                                            - "1.0"
                                          description: The version of the response schema
                                        result_type:
                                          type: string
                                          enum:
                                            - single
                                          description: A single object of the file resource.
                                        resource_type:
                                          type: string
                                          enum:
                                            - file
                                          description: Data contains the file resource.
                                        data:
                                          type: object
                                          properties:
                                            id:
                                              type: string
                                              format: cuid
                                              description: The unique identifier of the file
                                              example: cytp5m6ijs4rxs0erqsexample
                                            resource_type:
                                              type: string
                                              enum:
                                                - file
                                            filename:
                                              type: string
                                              minLength: 1
                                              description: The complete filename including the file extension
                                              example: my-file.pdf
                                            mime_type:
                                              type: string
                                              minLength: 1
                                              description: The mime type of the file
                                              example: application/pdf
                                            url:
                                              type: string
                                              format: url
                                              description: The signed read url of the file
                                              example: https://zigned.se
                                            metadata:
                                              type: object
                                              properties:
                                                lookup_key:
                                                  type: string
                                                  description: A provided lookup key provided by you to help you identify the
                                                    file.
                                                  example: file_tag
                                              required:
                                                - lookup_key
                                            created_at:
                                              type: string
                                              description: UTC datetime ISO string
                                              example: 2024-01-01T00:00:00.000Z
                                            updated_at:
                                              type: string
                                              description: UTC datetime ISO string
                                              example: 2024-01-01T00:00:00.000Z
                                          required:
                                            - id
                                            - resource_type
                                            - filename
                                            - mime_type
                                            - created_at
                                            - updated_at
                                          description: The resource data.
                                      required:
                                        - version
                                        - result_type
                                        - resource_type
                                        - data
                                    - type: string
                                      nullable: true
                                      format: "null"
                                  description: The main document which will be signed.
                                attachments:
                                  oneOf:
                                    - type: array
                                      items:
                                        type: string
                                        format: cuid
                                        minLength: 1
                                      description: List of all IDs for the attachments belonging to this agreement
                                      example:
                                        - c5lnvzb9saw7pkusnvcexample
                                        - cgizx0nvpnyzxupx0cvexample
                                        - codqlu3eiigxia664m3example
                                    - type: object
                                      properties:
                                        version:
                                          type: string
                                          enum:
                                            - "1.0"
                                          description: The version of the response schema
                                        result_type:
                                          type: string
                                          enum:
                                            - list
                                          description: A non-paginated list of the attachment resource.
                                        resource_type:
                                          type: string
                                          enum:
                                            - attachment
                                          description: Data contains the attachment resource.
                                        data:
                                          $ref: "#/components/schemas/18aea1f88c852890888d309ddd8605d8c0438d2b"
                                      required:
                                        - version
                                        - result_type
                                        - resource_type
                                        - data
                                    - type: string
                                      nullable: true
                                      format: "null"
                              required:
                                - main
                            signed_document:
                              oneOf:
                                - type: string
                                  format: cuid
                                  description: The unique identifier for the signed document
                                  example: ckfd2sygk12n9slxwkeexample
                                - type: object
                                  properties:
                                    version:
                                      type: string
                                      enum:
                                        - "1.0"
                                      description: The version of the response schema
                                    result_type:
                                      type: string
                                      enum:
                                        - single
                                      description: A single object of the file resource.
                                    resource_type:
                                      type: string
                                      enum:
                                        - file
                                      description: Data contains the file resource.
                                    data:
                                      type: object
                                      properties:
                                        id:
                                          type: string
                                          format: cuid
                                          description: The unique identifier of the file
                                          example: cytp5m6ijs4rxs0erqsexample
                                        resource_type:
                                          type: string
                                          enum:
                                            - file
                                        filename:
                                          type: string
                                          minLength: 1
                                          description: The complete filename including the file extension
                                          example: my-file.pdf
                                        mime_type:
                                          type: string
                                          minLength: 1
                                          description: The mime type of the file
                                          example: application/pdf
                                        url:
                                          type: string
                                          format: url
                                          description: The signed read url of the file
                                          example: https://zigned.se
                                        metadata:
                                          type: object
                                          properties:
                                            lookup_key:
                                              type: string
                                              description: A provided lookup key provided by you to help you identify the
                                                file.
                                              example: file_tag
                                          required:
                                            - lookup_key
                                        created_at:
                                          type: string
                                          description: UTC datetime ISO string
                                          example: 2024-01-01T00:00:00.000Z
                                        updated_at:
                                          type: string
                                          description: UTC datetime ISO string
                                          example: 2024-01-01T00:00:00.000Z
                                      required:
                                        - id
                                        - resource_type
                                        - filename
                                        - mime_type
                                        - created_at
                                        - updated_at
                                      description: The resource data.
                                  required:
                                    - version
                                    - result_type
                                    - resource_type
                                    - data
                                - type: string
                                  nullable: true
                                  format: "null"
                              description: The finalized and signed document.
                          required:
                            - original_documents
                            - signed_document
                        signing_order:
                          type: object
                          properties:
                            enabled:
                              type: boolean
                            grouped:
                              type: boolean
                          required:
                            - enabled
                            - grouped
                        communication:
                          type: object
                          properties:
                            send_emails:
                              type: boolean
                            default_locale:
                              nullable: true
                              type: string
                              enum:
                                - sv-SE
                                - en-US
                              description: The default locale for the agreement. Can be overridden by
                                individual participants/observers from the
                                signing room, but this value serves as the
                                default if nothing else is specified.
                            automatic_reminders:
                              type: object
                              properties:
                                enabled:
                                  type: boolean
                                intensity:
                                  nullable: true
                                  type: string
                                  enum:
                                    - intense
                                    - normal
                                  description: The intensity of the reminders. The reminders are scheduled with an
                                    exponential fall off, but the intensity
                                    regulates the base interval. If expiration
                                    date is set for the agreement, the reminders
                                    become more intense at the end.
                              required:
                                - enabled
                                - intensity
                            recipient_messages:
                              nullable: true
                              type: object
                              properties:
                                version:
                                  type: string
                                  enum:
                                    - "1.0"
                                  description: The version of the response schema
                                result_type:
                                  type: string
                                  enum:
                                    - single
                                  description: A single object of the recipient_message resource.
                                resource_type:
                                  type: string
                                  enum:
                                    - recipient_message
                                  description: Data contains the recipient_message resource.
                                data:
                                  type: object
                                  properties:
                                    id:
                                      type: string
                                      format: cuid
                                      description: The unique identifier of the recipient message
                                      example: ck1ayqgg0fuxdetcvjtexample
                                    resource_type:
                                      type: string
                                      enum:
                                        - recipient_message
                                    message_templates:
                                      type: object
                                      properties:
                                        version:
                                          type: string
                                          enum:
                                            - "1.0"
                                          description: The version of the response schema
                                        result_type:
                                          type: string
                                          enum:
                                            - list
                                          description: A non-paginated list of the recipient message template resource.
                                        resource_type:
                                          type: string
                                          enum:
                                            - recipient_message_template
                                          description: Data contains the recipient message template resource.
                                        data:
                                          $ref: "#/components/schemas/7aadbd48657236af70d97541a9c85c00b14e95a5"
                                      required:
                                        - version
                                        - result_type
                                        - resource_type
                                        - data
                                    message_template_variables:
                                      type: object
                                      properties:
                                        version:
                                          type: string
                                          enum:
                                            - "1.0"
                                          description: The version of the response schema
                                        result_type:
                                          type: string
                                          enum:
                                            - list
                                          description: A non-paginated list of the recipient message template variable
                                            resource.
                                        resource_type:
                                          type: string
                                          enum:
                                            - recipient_message_template_variable
                                          description: Data contains the recipient message template variable resource.
                                        data:
                                          $ref: "#/components/schemas/f9a847cbdf0e167d1aa8d3b7127afb96d878e823"
                                      required:
                                        - version
                                        - result_type
                                        - resource_type
                                        - data
                                    created_at:
                                      type: string
                                      description: UTC datetime ISO string
                                      example: 2024-01-01T00:00:00.000Z
                                    updated_at:
                                      type: string
                                      description: UTC datetime ISO string
                                      example: 2024-01-01T00:00:00.000Z
                                  required:
                                    - id
                                    - resource_type
                                    - message_templates
                                    - message_template_variables
                                    - created_at
                                    - updated_at
                                  description: The resource data.
                              required:
                                - version
                                - result_type
                                - resource_type
                                - data
                          required:
                            - send_emails
                        metadata:
                          type: object
                          properties:
                            mask_pii:
                              type: boolean
                              default: true
                              description: Whether to mask PII visually on the signed document. Default is
                                true. Note that this only affects the visual
                                representation of the PII, the actual PII is
                                still present in the evidence package or
                                certificate.
                            lookup_key:
                              type: string
                              description: A provided lookup key provided by you to help you identify the
                                agreement.
                              example: your_internal_customer_id
                            success_callback_url:
                              type: string
                              format: url
                              description: A provided callback url to refer the participants back to post
                                successful action.
                              example: https://yourdomain.com/sign-complete
                        expires_at:
                          nullable: true
                          type: string
                          description: UTC datetime ISO string
                          example: 2024-01-01T00:00:00.000Z
                        delete_scheduled_at:
                          nullable: true
                          type: string
                          description: The timestamp when deletion is scheduled to occur. Null if not
                            scheduled.
                          example: 2024-01-01T00:00:00.000Z
                        deleted_at:
                          nullable: true
                          type: string
                          description: The timestamp when the agreement was deleted. Null if not deleted.
                          example: 2024-01-01T00:00:00.000Z
                        deleted:
                          type: boolean
                          description: Whether the agreement has been deleted. Returns true if either
                            scheduled for deletion or if already deleted.
                        updated_at:
                          type: string
                          description: UTC datetime ISO string
                          example: 2024-01-01T00:00:00.000Z
                        created_at:
                          type: string
                          description: UTC datetime ISO string
                          example: 2024-01-01T00:00:00.000Z
                      required:
                        - id
                        - resource_type
                        - test_mode
                        - status
                        - cancellation_reason
                        - theme
                        - issuer
                        - participants
                        - signing_order
                        - communication
                        - updated_at
                        - created_at
                      description: The agreement resource
                    description: The resource data
                  pagination:
                    type: object
                    properties:
                      limit:
                        type: integer
                        format: int64
                        minimum: 0
                        exclusiveMinimum: true
                        maximum: 9007199254740991
                        exclusiveMaximum: false
                        description: The maximum number of items per page
                        example: 100
                      total_pages:
                        type: integer
                        format: int64
                        minimum: 0
                        exclusiveMinimum: true
                        maximum: 9007199254740991
                        exclusiveMaximum: false
                        description: The total number of pages
                        example: 10
                      page:
                        type: integer
                        format: int64
                        minimum: 0
                        exclusiveMinimum: true
                        maximum: 9007199254740991
                        exclusiveMaximum: false
                        description: The current page number
                        example: 1
                      total_results:
                        type: integer
                        format: int64
                        minimum: 0
                        exclusiveMinimum: false
                        maximum: 9007199254740991
                        exclusiveMaximum: false
                        description: The total number of results
                        example: 1000
                    required:
                      - limit
                      - total_pages
                      - page
                      - total_results
                    description: Contains the pagination meta data
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
                  - pagination
        "400":
          description: GET /agreements Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Retrieves a paginated list of all agreements created by the
        authenticated client
      summary: List Agreements
      tags:
        - Agreements
      parameters:
        - name: limit
          in: query
          required: false
          description: The number of agreements to return. Max 100
          schema:
            type: string
            default: "50"
            description: The number of agreements to return. Max 100
            example: "50"
        - name: page
          in: query
          required: false
          description: The page of agreements to return. Default 1
          schema:
            type: string
            default: "1"
            description: The page of agreements to return. Default 1
            example: "1"
        - name: order_by
          in: query
          required: false
          description: The agreements are ordered by date in descending order by default.
          schema:
            type: string
            enum:
              - desc
              - asc
            description: The agreements are ordered by date in descending order by default.
            example: desc
        - name: status
          in: query
          required: false
          description: The status of the agreements to return.
          schema:
            type: string
            enum:
              - draft
              - pending
              - fulfilled
              - cancelled
              - generating
              - failed_to_generate
              - open
              - expired
            description: The status of the agreements to return.
        - name: start_date
          in: query
          required: false
          description: The earliest creation date of the agreements to return.
          schema:
            description: The earliest creation date of the agreements to return.
            type: string
            format: date-time
            pattern: ^\d{4}-\d{2}-\d{2}(T\d{2}:\d{2}:\d{2}(\.\d+)?)?Z?$
            externalDocs:
              url: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString
        - name: end_date
          in: query
          required: false
          description: The latest creation date of the agreements to return.
          schema:
            description: The latest creation date of the agreements to return.
            type: string
            format: date-time
            pattern: ^\d{4}-\d{2}-\d{2}(T\d{2}:\d{2}:\d{2}(\.\d+)?)?Z?$
            externalDocs:
              url: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString
        - name: lookup_key
          in: query
          required: false
          description: The lookup key of the agreements to return
          schema:
            type: string
            description: The lookup key of the agreements to return
            example: my-internal-customer-id
        - name: include_deleted
          in: query
          required: false
          description: Whether to include deleted agreements. Default is false. If true,
            the agreements will be included even if they are deleted or
            scheduled for deletion. Deleted agreements have anonymized data and
            any files will have been permanently deleted.
          schema:
            type: string
            enum:
              - "true"
              - "false"
            description: Whether to include deleted agreements. Default is false. If true,
              the agreements will be included even if they are deleted or
              scheduled for deletion. Deleted agreements have anonymized data
              and any files will have been permanently deleted.
      security:
        - HTTP_1: []
    post:
      operationId: PostAgreements
      responses:
        "200":
          description: POST /agreements Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the agreement resource.
                  resource_type:
                    type: string
                    enum:
                      - agreement
                    description: Data contains the agreement resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the agreement
                        example: cckmmstwimwnfgqvuajexample
                      resource_type:
                        type: string
                        enum:
                          - agreement
                      test_mode:
                        type: boolean
                        description: Indicates if the agreement is created using a development client
                      status:
                        type: string
                        enum:
                          - draft
                          - pending
                          - fulfilled
                          - cancelled
                          - generating
                          - failed_to_generate
                          - open
                          - expired
                        description: The status of the agreement
                      trust_level:
                        type: string
                        enum:
                          - SES
                          - AES
                          - QES
                        description: The minimum trust level  for the signatures.
                      cancellation_reason:
                        nullable: true
                        type: string
                        description: If the agreement is in a cancelled state, this will be a short
                          description on the reason why, otherwise it will be
                          null.
                        example: null
                      theme:
                        oneOf:
                          - type: string
                            format: cuid
                            description: The unique identifier for the theme attached to the agreement
                            example: ccrirlws7dyjk2rzo2aexample
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - single
                                description: A single object of the theme resource.
                              resource_type:
                                type: string
                                enum:
                                  - theme
                                description: Data contains the theme resource.
                              data:
                                type: object
                                properties:
                                  id:
                                    type: string
                                    format: cuid
                                    description: The unique identifier of the theme
                                    example: coerir2amisfebqzdooexample
                                  resource_type:
                                    type: string
                                    enum:
                                      - theme
                                  logo:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                    description: The logo of the theme. This is displayed to the user in all
                                      communication and touch points.
                                  icon:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                    description: The icon of the theme. This is used for the favicon.
                                  primary_color:
                                    type: string
                                    default: "#000000"
                                    description: The primary color used to create the color palette in the signing
                                      room.
                                    example: "#000000"
                                  metadata:
                                    type: object
                                    properties:
                                      lookup_key:
                                        type: string
                                        description: A provided lookup key provided by you to help you identify the
                                          theme.
                                        example: your_internal_customer_id
                                    required:
                                      - lookup_key
                                  created_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                  updated_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                required:
                                  - id
                                  - resource_type
                                  - logo
                                  - icon
                                  - created_at
                                  - updated_at
                                description: The resource data.
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      issuer:
                        type: object
                        properties:
                          name:
                            nullable: true
                            type: string
                            description: The name of the issuer. Required if no email is provided.
                            example: John Doe
                          email:
                            nullable: true
                            type: string
                            description: The email of the issuer. Required if agreemnt is configured to send
                              emails.
                            example: example@example.com
                          role:
                            type: string
                            enum:
                              - signer
                              - approver
                              - observer
                            description: The role of the issuer in the agreement process.
                          participant_id:
                            type: string
                            format: cuid
                            description: If the issuer is a signer or approver this is the ID of the related
                              participant.
                            example: cd0jga4zijaebyga1wlexample
                          signing_room_url:
                            nullable: true
                            type: string
                            format: url
                            example: https://www.zigned.se/sign/cjecfacxrxzqd9def5zexample/cmakdfl6yfb9ls8h6jyexample
                            description: The URL to the signing room for the issuer. Only available after
                              the agreement has been finalized for signing.
                          locale:
                            nullable: true
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                            description: The locale for the issuer. Can be overridden from the signing room,
                              but this value serves as the default if nothing
                              else is specified. If omitted, the default_locale
                              of the agreement is used.
                        required:
                          - name
                          - email
                          - role
                          - signing_room_url
                        description: The issuer of the agreement
                      participants:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the participants belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the participant resource.
                              resource_type:
                                type: string
                                enum:
                                  - participant
                                description: Data contains the participant resource.
                              data:
                                $ref: "#/components/schemas/95c1af3f45da65daeedb661f70210b46b2bd71d5"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      observers:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the observers belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the observer resource.
                              resource_type:
                                type: string
                                enum:
                                  - observer
                                description: Data contains the observer resource.
                              data:
                                $ref: "#/components/schemas/c893c5c1d97a5bcbd8972ce188f48f8f75c6a171"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      signing_groups:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the signing groups belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the signing group resource.
                              resource_type:
                                type: string
                                enum:
                                  - signing_group
                                description: Data contains the signing group resource.
                              data:
                                $ref: "#/components/schemas/d69cfbd1e408327b80080ee78c087563df3370f4"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      documents:
                        type: object
                        properties:
                          original_documents:
                            type: object
                            properties:
                              main:
                                oneOf:
                                  - type: string
                                    format: cuid
                                    description: The unique identifier of the main document
                                    example: cmwqhs06osj0tus71kcexample
                                  - type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  - type: string
                                    nullable: true
                                    format: "null"
                                description: The main document which will be signed.
                              attachments:
                                oneOf:
                                  - type: array
                                    items:
                                      type: string
                                      format: cuid
                                      minLength: 1
                                    description: List of all IDs for the attachments belonging to this agreement
                                    example:
                                      - c5lnvzb9saw7pkusnvcexample
                                      - cgizx0nvpnyzxupx0cvexample
                                      - codqlu3eiigxia664m3example
                                  - type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the attachment resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - attachment
                                        description: Data contains the attachment resource.
                                      data:
                                        $ref: "#/components/schemas/18aea1f88c852890888d309ddd8605d8c0438d2b"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  - type: string
                                    nullable: true
                                    format: "null"
                            required:
                              - main
                          signed_document:
                            oneOf:
                              - type: string
                                format: cuid
                                description: The unique identifier for the signed document
                                example: ckfd2sygk12n9slxwkeexample
                              - type: object
                                properties:
                                  version:
                                    type: string
                                    enum:
                                      - "1.0"
                                    description: The version of the response schema
                                  result_type:
                                    type: string
                                    enum:
                                      - single
                                    description: A single object of the file resource.
                                  resource_type:
                                    type: string
                                    enum:
                                      - file
                                    description: Data contains the file resource.
                                  data:
                                    type: object
                                    properties:
                                      id:
                                        type: string
                                        format: cuid
                                        description: The unique identifier of the file
                                        example: cytp5m6ijs4rxs0erqsexample
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                      filename:
                                        type: string
                                        minLength: 1
                                        description: The complete filename including the file extension
                                        example: my-file.pdf
                                      mime_type:
                                        type: string
                                        minLength: 1
                                        description: The mime type of the file
                                        example: application/pdf
                                      url:
                                        type: string
                                        format: url
                                        description: The signed read url of the file
                                        example: https://zigned.se
                                      metadata:
                                        type: object
                                        properties:
                                          lookup_key:
                                            type: string
                                            description: A provided lookup key provided by you to help you identify the
                                              file.
                                            example: file_tag
                                        required:
                                          - lookup_key
                                      created_at:
                                        type: string
                                        description: UTC datetime ISO string
                                        example: 2024-01-01T00:00:00.000Z
                                      updated_at:
                                        type: string
                                        description: UTC datetime ISO string
                                        example: 2024-01-01T00:00:00.000Z
                                    required:
                                      - id
                                      - resource_type
                                      - filename
                                      - mime_type
                                      - created_at
                                      - updated_at
                                    description: The resource data.
                                required:
                                  - version
                                  - result_type
                                  - resource_type
                                  - data
                              - type: string
                                nullable: true
                                format: "null"
                            description: The finalized and signed document.
                        required:
                          - original_documents
                          - signed_document
                      signing_order:
                        type: object
                        properties:
                          enabled:
                            type: boolean
                          grouped:
                            type: boolean
                        required:
                          - enabled
                          - grouped
                      communication:
                        type: object
                        properties:
                          send_emails:
                            type: boolean
                          default_locale:
                            nullable: true
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                            description: The default locale for the agreement. Can be overridden by
                              individual participants/observers from the signing
                              room, but this value serves as the default if
                              nothing else is specified.
                          automatic_reminders:
                            type: object
                            properties:
                              enabled:
                                type: boolean
                              intensity:
                                nullable: true
                                type: string
                                enum:
                                  - intense
                                  - normal
                                description: The intensity of the reminders. The reminders are scheduled with an
                                  exponential fall off, but the intensity
                                  regulates the base interval. If expiration
                                  date is set for the agreement, the reminders
                                  become more intense at the end.
                            required:
                              - enabled
                              - intensity
                          recipient_messages:
                            nullable: true
                            type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - single
                                description: A single object of the recipient_message resource.
                              resource_type:
                                type: string
                                enum:
                                  - recipient_message
                                description: Data contains the recipient_message resource.
                              data:
                                type: object
                                properties:
                                  id:
                                    type: string
                                    format: cuid
                                    description: The unique identifier of the recipient message
                                    example: ck1ayqgg0fuxdetcvjtexample
                                  resource_type:
                                    type: string
                                    enum:
                                      - recipient_message
                                  message_templates:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the recipient message template resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - recipient_message_template
                                        description: Data contains the recipient message template resource.
                                      data:
                                        $ref: "#/components/schemas/7aadbd48657236af70d97541a9c85c00b14e95a5"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  message_template_variables:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the recipient message template variable
                                          resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - recipient_message_template_variable
                                        description: Data contains the recipient message template variable resource.
                                      data:
                                        $ref: "#/components/schemas/f9a847cbdf0e167d1aa8d3b7127afb96d878e823"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  created_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                  updated_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                required:
                                  - id
                                  - resource_type
                                  - message_templates
                                  - message_template_variables
                                  - created_at
                                  - updated_at
                                description: The resource data.
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                        required:
                          - send_emails
                      metadata:
                        type: object
                        properties:
                          mask_pii:
                            type: boolean
                            default: true
                            description: Whether to mask PII visually on the signed document. Default is
                              true. Note that this only affects the visual
                              representation of the PII, the actual PII is still
                              present in the evidence package or certificate.
                          lookup_key:
                            type: string
                            description: A provided lookup key provided by you to help you identify the
                              agreement.
                            example: your_internal_customer_id
                          success_callback_url:
                            type: string
                            format: url
                            description: A provided callback url to refer the participants back to post
                              successful action.
                            example: https://yourdomain.com/sign-complete
                      expires_at:
                        nullable: true
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      delete_scheduled_at:
                        nullable: true
                        type: string
                        description: The timestamp when deletion is scheduled to occur. Null if not
                          scheduled.
                        example: 2024-01-01T00:00:00.000Z
                      deleted_at:
                        nullable: true
                        type: string
                        description: The timestamp when the agreement was deleted. Null if not deleted.
                        example: 2024-01-01T00:00:00.000Z
                      deleted:
                        type: boolean
                        description: Whether the agreement has been deleted. Returns true if either
                          scheduled for deletion or if already deleted.
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - test_mode
                      - status
                      - cancellation_reason
                      - theme
                      - issuer
                      - participants
                      - signing_order
                      - communication
                      - updated_at
                      - created_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: POST /agreements Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Creates a new agreement in draft status. Use the agreement ID in
        subsequent requests.
      summary: Create an Agreement
      tags:
        - agreements
      requestBody:
        description: POST /agreements request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - type: object
                          properties: {}
                        - type: object
                          properties: {}
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    issuer:
                      type: object
                      properties:
                        name:
                          type: string
                          description: The name of the issuer
                          example: John Doe
                        email:
                          type: string
                          description: The email of the issuer. Will be used for communication if email
                            communication is enabled for the agreement.
                          example: example@example.com
                        role:
                          type: string
                          enum:
                            - observer
                            - signer
                            - approver
                          default: observer
                          description: The role of the issuer within the signing process.
                        locale:
                          type: string
                          enum:
                            - sv-SE
                            - en-US
                          default: sv-SE
                          description: Optional. The locale for the issuer of the signing process. Can be
                            overridden in the signing room, but the locale
                            provided by you will serve as the default in initial
                            communication. If not specified, the default locale
                            for the agreement will be used.
                      description: The issuer of the agreement. If not provided, the authenticated
                        client will be used.
                    send_emails:
                      type: boolean
                      default: true
                      description: Enables email communication in the agreement process. If not
                        provided, the default value is true. If disabled, you
                        will be responsible for handling all communication.
                    mask_pii:
                      type: boolean
                      description: Whether to mask PII visually on the signed document. Default is
                        true. Note that this only affects the visual
                        representation of the PII, the actual PII is still
                        present in the evidence package or certificate.
                    automatic_reminders:
                      type: string
                      enum:
                        - intense
                        - normal
                      description: Enables automatic reminders for all participants. Disabled by
                        default. If disabled, you can still manually send
                        reminders via the `/reminders` endpoint or via the
                        signing room.
                    trust_level:
                      type: string
                      enum:
                        - SES
                        - AES
                        - QES
                      default: SES
                      description: The minimum trust level used for all signatures in accordance with
                        the eIDAS regulation. If not provided, the default value
                        is SES.
                    signing_order:
                      type: boolean
                      default: false
                      description: Enables signing order for the agreement process. If not provided,
                        the default value is false. If enabled, the signers will
                        be required to sign in the order in which they are
                        defined.
                    theme_id:
                      type: string
                      format: cuid
                      description: The ID of the theme to use for the agreement.
                      example: chnum1sn81uhb0msxecexample
                    default_locale:
                      type: string
                      enum:
                        - sv-SE
                        - en-US
                      default: sv-SE
                      description: The default locale of the signing process. Can be overridden by
                        individual participants, but the default locale
                        determines the primary language used in  all
                        communication and UI.
                    lookup_key:
                      type: string
                      description: Arbitrary string used to identify the agreement. This ID will be
                        returned in the metadata field of the agreement
                        resource.
                      example: my-internal-customer-id
                    expires_at:
                      description: Set an expiration date for the signing process. The agreement will
                        be automatically marked as expired after this date and
                        won't be able to be signed. Time part of the date will
                        be ignored and set to 23:59:59:999 UTC.
                      type: string
                      format: date-time
                      pattern: ^\d{4}-\d{2}-\d{2}(T\d{2}:\d{2}:\d{2}(\.\d+)?)?Z?$
                      externalDocs:
                        url: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString
                    success_callback_url:
                      type: string
                      format: url
                      description: An optional callback url to refer the participants back to post
                        taking action.
                      example: https://your-domain.com/sign-complete
      security:
        - HTTP_1: []
  /agreements/{agreement_id}:
    get:
      operationId: GetAgreementsAgreementId
      responses:
        "200":
          description: GET /agreements/:agreement_id Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the agreement resource.
                  resource_type:
                    type: string
                    enum:
                      - agreement
                    description: Data contains the agreement resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the agreement
                        example: cckmmstwimwnfgqvuajexample
                      resource_type:
                        type: string
                        enum:
                          - agreement
                      test_mode:
                        type: boolean
                        description: Indicates if the agreement is created using a development client
                      status:
                        type: string
                        enum:
                          - draft
                          - pending
                          - fulfilled
                          - cancelled
                          - generating
                          - failed_to_generate
                          - open
                          - expired
                        description: The status of the agreement
                      trust_level:
                        type: string
                        enum:
                          - SES
                          - AES
                          - QES
                        description: The minimum trust level  for the signatures.
                      cancellation_reason:
                        nullable: true
                        type: string
                        description: If the agreement is in a cancelled state, this will be a short
                          description on the reason why, otherwise it will be
                          null.
                        example: null
                      theme:
                        oneOf:
                          - type: string
                            format: cuid
                            description: The unique identifier for the theme attached to the agreement
                            example: ccrirlws7dyjk2rzo2aexample
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - single
                                description: A single object of the theme resource.
                              resource_type:
                                type: string
                                enum:
                                  - theme
                                description: Data contains the theme resource.
                              data:
                                type: object
                                properties:
                                  id:
                                    type: string
                                    format: cuid
                                    description: The unique identifier of the theme
                                    example: coerir2amisfebqzdooexample
                                  resource_type:
                                    type: string
                                    enum:
                                      - theme
                                  logo:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                    description: The logo of the theme. This is displayed to the user in all
                                      communication and touch points.
                                  icon:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                    description: The icon of the theme. This is used for the favicon.
                                  primary_color:
                                    type: string
                                    default: "#000000"
                                    description: The primary color used to create the color palette in the signing
                                      room.
                                    example: "#000000"
                                  metadata:
                                    type: object
                                    properties:
                                      lookup_key:
                                        type: string
                                        description: A provided lookup key provided by you to help you identify the
                                          theme.
                                        example: your_internal_customer_id
                                    required:
                                      - lookup_key
                                  created_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                  updated_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                required:
                                  - id
                                  - resource_type
                                  - logo
                                  - icon
                                  - created_at
                                  - updated_at
                                description: The resource data.
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      issuer:
                        type: object
                        properties:
                          name:
                            nullable: true
                            type: string
                            description: The name of the issuer. Required if no email is provided.
                            example: John Doe
                          email:
                            nullable: true
                            type: string
                            description: The email of the issuer. Required if agreemnt is configured to send
                              emails.
                            example: example@example.com
                          role:
                            type: string
                            enum:
                              - signer
                              - approver
                              - observer
                            description: The role of the issuer in the agreement process.
                          participant_id:
                            type: string
                            format: cuid
                            description: If the issuer is a signer or approver this is the ID of the related
                              participant.
                            example: cd0jga4zijaebyga1wlexample
                          signing_room_url:
                            nullable: true
                            type: string
                            format: url
                            example: https://www.zigned.se/sign/cjecfacxrxzqd9def5zexample/cmakdfl6yfb9ls8h6jyexample
                            description: The URL to the signing room for the issuer. Only available after
                              the agreement has been finalized for signing.
                          locale:
                            nullable: true
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                            description: The locale for the issuer. Can be overridden from the signing room,
                              but this value serves as the default if nothing
                              else is specified. If omitted, the default_locale
                              of the agreement is used.
                        required:
                          - name
                          - email
                          - role
                          - signing_room_url
                        description: The issuer of the agreement
                      participants:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the participants belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the participant resource.
                              resource_type:
                                type: string
                                enum:
                                  - participant
                                description: Data contains the participant resource.
                              data:
                                $ref: "#/components/schemas/95c1af3f45da65daeedb661f70210b46b2bd71d5"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      observers:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the observers belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the observer resource.
                              resource_type:
                                type: string
                                enum:
                                  - observer
                                description: Data contains the observer resource.
                              data:
                                $ref: "#/components/schemas/c893c5c1d97a5bcbd8972ce188f48f8f75c6a171"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      signing_groups:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the signing groups belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the signing group resource.
                              resource_type:
                                type: string
                                enum:
                                  - signing_group
                                description: Data contains the signing group resource.
                              data:
                                $ref: "#/components/schemas/d69cfbd1e408327b80080ee78c087563df3370f4"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      documents:
                        type: object
                        properties:
                          original_documents:
                            type: object
                            properties:
                              main:
                                oneOf:
                                  - type: string
                                    format: cuid
                                    description: The unique identifier of the main document
                                    example: cmwqhs06osj0tus71kcexample
                                  - type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  - type: string
                                    nullable: true
                                    format: "null"
                                description: The main document which will be signed.
                              attachments:
                                oneOf:
                                  - type: array
                                    items:
                                      type: string
                                      format: cuid
                                      minLength: 1
                                    description: List of all IDs for the attachments belonging to this agreement
                                    example:
                                      - c5lnvzb9saw7pkusnvcexample
                                      - cgizx0nvpnyzxupx0cvexample
                                      - codqlu3eiigxia664m3example
                                  - type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the attachment resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - attachment
                                        description: Data contains the attachment resource.
                                      data:
                                        $ref: "#/components/schemas/18aea1f88c852890888d309ddd8605d8c0438d2b"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  - type: string
                                    nullable: true
                                    format: "null"
                            required:
                              - main
                          signed_document:
                            oneOf:
                              - type: string
                                format: cuid
                                description: The unique identifier for the signed document
                                example: ckfd2sygk12n9slxwkeexample
                              - type: object
                                properties:
                                  version:
                                    type: string
                                    enum:
                                      - "1.0"
                                    description: The version of the response schema
                                  result_type:
                                    type: string
                                    enum:
                                      - single
                                    description: A single object of the file resource.
                                  resource_type:
                                    type: string
                                    enum:
                                      - file
                                    description: Data contains the file resource.
                                  data:
                                    type: object
                                    properties:
                                      id:
                                        type: string
                                        format: cuid
                                        description: The unique identifier of the file
                                        example: cytp5m6ijs4rxs0erqsexample
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                      filename:
                                        type: string
                                        minLength: 1
                                        description: The complete filename including the file extension
                                        example: my-file.pdf
                                      mime_type:
                                        type: string
                                        minLength: 1
                                        description: The mime type of the file
                                        example: application/pdf
                                      url:
                                        type: string
                                        format: url
                                        description: The signed read url of the file
                                        example: https://zigned.se
                                      metadata:
                                        type: object
                                        properties:
                                          lookup_key:
                                            type: string
                                            description: A provided lookup key provided by you to help you identify the
                                              file.
                                            example: file_tag
                                        required:
                                          - lookup_key
                                      created_at:
                                        type: string
                                        description: UTC datetime ISO string
                                        example: 2024-01-01T00:00:00.000Z
                                      updated_at:
                                        type: string
                                        description: UTC datetime ISO string
                                        example: 2024-01-01T00:00:00.000Z
                                    required:
                                      - id
                                      - resource_type
                                      - filename
                                      - mime_type
                                      - created_at
                                      - updated_at
                                    description: The resource data.
                                required:
                                  - version
                                  - result_type
                                  - resource_type
                                  - data
                              - type: string
                                nullable: true
                                format: "null"
                            description: The finalized and signed document.
                        required:
                          - original_documents
                          - signed_document
                      signing_order:
                        type: object
                        properties:
                          enabled:
                            type: boolean
                          grouped:
                            type: boolean
                        required:
                          - enabled
                          - grouped
                      communication:
                        type: object
                        properties:
                          send_emails:
                            type: boolean
                          default_locale:
                            nullable: true
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                            description: The default locale for the agreement. Can be overridden by
                              individual participants/observers from the signing
                              room, but this value serves as the default if
                              nothing else is specified.
                          automatic_reminders:
                            type: object
                            properties:
                              enabled:
                                type: boolean
                              intensity:
                                nullable: true
                                type: string
                                enum:
                                  - intense
                                  - normal
                                description: The intensity of the reminders. The reminders are scheduled with an
                                  exponential fall off, but the intensity
                                  regulates the base interval. If expiration
                                  date is set for the agreement, the reminders
                                  become more intense at the end.
                            required:
                              - enabled
                              - intensity
                          recipient_messages:
                            nullable: true
                            type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - single
                                description: A single object of the recipient_message resource.
                              resource_type:
                                type: string
                                enum:
                                  - recipient_message
                                description: Data contains the recipient_message resource.
                              data:
                                type: object
                                properties:
                                  id:
                                    type: string
                                    format: cuid
                                    description: The unique identifier of the recipient message
                                    example: ck1ayqgg0fuxdetcvjtexample
                                  resource_type:
                                    type: string
                                    enum:
                                      - recipient_message
                                  message_templates:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the recipient message template resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - recipient_message_template
                                        description: Data contains the recipient message template resource.
                                      data:
                                        $ref: "#/components/schemas/7aadbd48657236af70d97541a9c85c00b14e95a5"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  message_template_variables:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the recipient message template variable
                                          resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - recipient_message_template_variable
                                        description: Data contains the recipient message template variable resource.
                                      data:
                                        $ref: "#/components/schemas/f9a847cbdf0e167d1aa8d3b7127afb96d878e823"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  created_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                  updated_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                required:
                                  - id
                                  - resource_type
                                  - message_templates
                                  - message_template_variables
                                  - created_at
                                  - updated_at
                                description: The resource data.
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                        required:
                          - send_emails
                      metadata:
                        type: object
                        properties:
                          mask_pii:
                            type: boolean
                            default: true
                            description: Whether to mask PII visually on the signed document. Default is
                              true. Note that this only affects the visual
                              representation of the PII, the actual PII is still
                              present in the evidence package or certificate.
                          lookup_key:
                            type: string
                            description: A provided lookup key provided by you to help you identify the
                              agreement.
                            example: your_internal_customer_id
                          success_callback_url:
                            type: string
                            format: url
                            description: A provided callback url to refer the participants back to post
                              successful action.
                            example: https://yourdomain.com/sign-complete
                      expires_at:
                        nullable: true
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      delete_scheduled_at:
                        nullable: true
                        type: string
                        description: The timestamp when deletion is scheduled to occur. Null if not
                          scheduled.
                        example: 2024-01-01T00:00:00.000Z
                      deleted_at:
                        nullable: true
                        type: string
                        description: The timestamp when the agreement was deleted. Null if not deleted.
                        example: 2024-01-01T00:00:00.000Z
                      deleted:
                        type: boolean
                        description: Whether the agreement has been deleted. Returns true if either
                          scheduled for deletion or if already deleted.
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - test_mode
                      - status
                      - cancellation_reason
                      - theme
                      - issuer
                      - participants
                      - signing_order
                      - communication
                      - updated_at
                      - created_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: GET /agreements/:agreement_id Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Retrieves a single agreement created by the authenticated client.
      summary: Retrieve an Agreement
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: The ID of the agreement to retrieve
          schema:
            type: string
            format: cuid
            description: The ID of the agreement to retrieve
            example: cympqvllke49zrmlh5aexample
      security:
        - HTTP_1: []
    put:
      operationId: PutAgreementsAgreementId
      responses:
        "200":
          description: PUT /agreements/:agreement_id Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the agreement resource.
                  resource_type:
                    type: string
                    enum:
                      - agreement
                    description: Data contains the agreement resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the agreement
                        example: cckmmstwimwnfgqvuajexample
                      resource_type:
                        type: string
                        enum:
                          - agreement
                      test_mode:
                        type: boolean
                        description: Indicates if the agreement is created using a development client
                      status:
                        type: string
                        enum:
                          - draft
                          - pending
                          - fulfilled
                          - cancelled
                          - generating
                          - failed_to_generate
                          - open
                          - expired
                        description: The status of the agreement
                      trust_level:
                        type: string
                        enum:
                          - SES
                          - AES
                          - QES
                        description: The minimum trust level  for the signatures.
                      cancellation_reason:
                        nullable: true
                        type: string
                        description: If the agreement is in a cancelled state, this will be a short
                          description on the reason why, otherwise it will be
                          null.
                        example: null
                      theme:
                        oneOf:
                          - type: string
                            format: cuid
                            description: The unique identifier for the theme attached to the agreement
                            example: ccrirlws7dyjk2rzo2aexample
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - single
                                description: A single object of the theme resource.
                              resource_type:
                                type: string
                                enum:
                                  - theme
                                description: Data contains the theme resource.
                              data:
                                type: object
                                properties:
                                  id:
                                    type: string
                                    format: cuid
                                    description: The unique identifier of the theme
                                    example: coerir2amisfebqzdooexample
                                  resource_type:
                                    type: string
                                    enum:
                                      - theme
                                  logo:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                    description: The logo of the theme. This is displayed to the user in all
                                      communication and touch points.
                                  icon:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                    description: The icon of the theme. This is used for the favicon.
                                  primary_color:
                                    type: string
                                    default: "#000000"
                                    description: The primary color used to create the color palette in the signing
                                      room.
                                    example: "#000000"
                                  metadata:
                                    type: object
                                    properties:
                                      lookup_key:
                                        type: string
                                        description: A provided lookup key provided by you to help you identify the
                                          theme.
                                        example: your_internal_customer_id
                                    required:
                                      - lookup_key
                                  created_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                  updated_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                required:
                                  - id
                                  - resource_type
                                  - logo
                                  - icon
                                  - created_at
                                  - updated_at
                                description: The resource data.
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      issuer:
                        type: object
                        properties:
                          name:
                            nullable: true
                            type: string
                            description: The name of the issuer. Required if no email is provided.
                            example: John Doe
                          email:
                            nullable: true
                            type: string
                            description: The email of the issuer. Required if agreemnt is configured to send
                              emails.
                            example: example@example.com
                          role:
                            type: string
                            enum:
                              - signer
                              - approver
                              - observer
                            description: The role of the issuer in the agreement process.
                          participant_id:
                            type: string
                            format: cuid
                            description: If the issuer is a signer or approver this is the ID of the related
                              participant.
                            example: cd0jga4zijaebyga1wlexample
                          signing_room_url:
                            nullable: true
                            type: string
                            format: url
                            example: https://www.zigned.se/sign/cjecfacxrxzqd9def5zexample/cmakdfl6yfb9ls8h6jyexample
                            description: The URL to the signing room for the issuer. Only available after
                              the agreement has been finalized for signing.
                          locale:
                            nullable: true
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                            description: The locale for the issuer. Can be overridden from the signing room,
                              but this value serves as the default if nothing
                              else is specified. If omitted, the default_locale
                              of the agreement is used.
                        required:
                          - name
                          - email
                          - role
                          - signing_room_url
                        description: The issuer of the agreement
                      participants:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the participants belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the participant resource.
                              resource_type:
                                type: string
                                enum:
                                  - participant
                                description: Data contains the participant resource.
                              data:
                                $ref: "#/components/schemas/95c1af3f45da65daeedb661f70210b46b2bd71d5"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      observers:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the observers belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the observer resource.
                              resource_type:
                                type: string
                                enum:
                                  - observer
                                description: Data contains the observer resource.
                              data:
                                $ref: "#/components/schemas/c893c5c1d97a5bcbd8972ce188f48f8f75c6a171"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      signing_groups:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the signing groups belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the signing group resource.
                              resource_type:
                                type: string
                                enum:
                                  - signing_group
                                description: Data contains the signing group resource.
                              data:
                                $ref: "#/components/schemas/d69cfbd1e408327b80080ee78c087563df3370f4"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      documents:
                        type: object
                        properties:
                          original_documents:
                            type: object
                            properties:
                              main:
                                oneOf:
                                  - type: string
                                    format: cuid
                                    description: The unique identifier of the main document
                                    example: cmwqhs06osj0tus71kcexample
                                  - type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  - type: string
                                    nullable: true
                                    format: "null"
                                description: The main document which will be signed.
                              attachments:
                                oneOf:
                                  - type: array
                                    items:
                                      type: string
                                      format: cuid
                                      minLength: 1
                                    description: List of all IDs for the attachments belonging to this agreement
                                    example:
                                      - c5lnvzb9saw7pkusnvcexample
                                      - cgizx0nvpnyzxupx0cvexample
                                      - codqlu3eiigxia664m3example
                                  - type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the attachment resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - attachment
                                        description: Data contains the attachment resource.
                                      data:
                                        $ref: "#/components/schemas/18aea1f88c852890888d309ddd8605d8c0438d2b"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  - type: string
                                    nullable: true
                                    format: "null"
                            required:
                              - main
                          signed_document:
                            oneOf:
                              - type: string
                                format: cuid
                                description: The unique identifier for the signed document
                                example: ckfd2sygk12n9slxwkeexample
                              - type: object
                                properties:
                                  version:
                                    type: string
                                    enum:
                                      - "1.0"
                                    description: The version of the response schema
                                  result_type:
                                    type: string
                                    enum:
                                      - single
                                    description: A single object of the file resource.
                                  resource_type:
                                    type: string
                                    enum:
                                      - file
                                    description: Data contains the file resource.
                                  data:
                                    type: object
                                    properties:
                                      id:
                                        type: string
                                        format: cuid
                                        description: The unique identifier of the file
                                        example: cytp5m6ijs4rxs0erqsexample
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                      filename:
                                        type: string
                                        minLength: 1
                                        description: The complete filename including the file extension
                                        example: my-file.pdf
                                      mime_type:
                                        type: string
                                        minLength: 1
                                        description: The mime type of the file
                                        example: application/pdf
                                      url:
                                        type: string
                                        format: url
                                        description: The signed read url of the file
                                        example: https://zigned.se
                                      metadata:
                                        type: object
                                        properties:
                                          lookup_key:
                                            type: string
                                            description: A provided lookup key provided by you to help you identify the
                                              file.
                                            example: file_tag
                                        required:
                                          - lookup_key
                                      created_at:
                                        type: string
                                        description: UTC datetime ISO string
                                        example: 2024-01-01T00:00:00.000Z
                                      updated_at:
                                        type: string
                                        description: UTC datetime ISO string
                                        example: 2024-01-01T00:00:00.000Z
                                    required:
                                      - id
                                      - resource_type
                                      - filename
                                      - mime_type
                                      - created_at
                                      - updated_at
                                    description: The resource data.
                                required:
                                  - version
                                  - result_type
                                  - resource_type
                                  - data
                              - type: string
                                nullable: true
                                format: "null"
                            description: The finalized and signed document.
                        required:
                          - original_documents
                          - signed_document
                      signing_order:
                        type: object
                        properties:
                          enabled:
                            type: boolean
                          grouped:
                            type: boolean
                        required:
                          - enabled
                          - grouped
                      communication:
                        type: object
                        properties:
                          send_emails:
                            type: boolean
                          default_locale:
                            nullable: true
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                            description: The default locale for the agreement. Can be overridden by
                              individual participants/observers from the signing
                              room, but this value serves as the default if
                              nothing else is specified.
                          automatic_reminders:
                            type: object
                            properties:
                              enabled:
                                type: boolean
                              intensity:
                                nullable: true
                                type: string
                                enum:
                                  - intense
                                  - normal
                                description: The intensity of the reminders. The reminders are scheduled with an
                                  exponential fall off, but the intensity
                                  regulates the base interval. If expiration
                                  date is set for the agreement, the reminders
                                  become more intense at the end.
                            required:
                              - enabled
                              - intensity
                          recipient_messages:
                            nullable: true
                            type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - single
                                description: A single object of the recipient_message resource.
                              resource_type:
                                type: string
                                enum:
                                  - recipient_message
                                description: Data contains the recipient_message resource.
                              data:
                                type: object
                                properties:
                                  id:
                                    type: string
                                    format: cuid
                                    description: The unique identifier of the recipient message
                                    example: ck1ayqgg0fuxdetcvjtexample
                                  resource_type:
                                    type: string
                                    enum:
                                      - recipient_message
                                  message_templates:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the recipient message template resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - recipient_message_template
                                        description: Data contains the recipient message template resource.
                                      data:
                                        $ref: "#/components/schemas/7aadbd48657236af70d97541a9c85c00b14e95a5"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  message_template_variables:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the recipient message template variable
                                          resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - recipient_message_template_variable
                                        description: Data contains the recipient message template variable resource.
                                      data:
                                        $ref: "#/components/schemas/f9a847cbdf0e167d1aa8d3b7127afb96d878e823"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  created_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                  updated_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                required:
                                  - id
                                  - resource_type
                                  - message_templates
                                  - message_template_variables
                                  - created_at
                                  - updated_at
                                description: The resource data.
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                        required:
                          - send_emails
                      metadata:
                        type: object
                        properties:
                          mask_pii:
                            type: boolean
                            default: true
                            description: Whether to mask PII visually on the signed document. Default is
                              true. Note that this only affects the visual
                              representation of the PII, the actual PII is still
                              present in the evidence package or certificate.
                          lookup_key:
                            type: string
                            description: A provided lookup key provided by you to help you identify the
                              agreement.
                            example: your_internal_customer_id
                          success_callback_url:
                            type: string
                            format: url
                            description: A provided callback url to refer the participants back to post
                              successful action.
                            example: https://yourdomain.com/sign-complete
                      expires_at:
                        nullable: true
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      delete_scheduled_at:
                        nullable: true
                        type: string
                        description: The timestamp when deletion is scheduled to occur. Null if not
                          scheduled.
                        example: 2024-01-01T00:00:00.000Z
                      deleted_at:
                        nullable: true
                        type: string
                        description: The timestamp when the agreement was deleted. Null if not deleted.
                        example: 2024-01-01T00:00:00.000Z
                      deleted:
                        type: boolean
                        description: Whether the agreement has been deleted. Returns true if either
                          scheduled for deletion or if already deleted.
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - test_mode
                      - status
                      - cancellation_reason
                      - theme
                      - issuer
                      - participants
                      - signing_order
                      - communication
                      - updated_at
                      - created_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: PUT /agreements/:agreement_id Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Updates an agreement. The agreement must be in draft or open status.
      summary: Update an Agreement
      tags:
        - Agreements
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: PUT /agreements/:agreement_id parameter
          schema:
            type: string
            format: cuid
            example: cdzwzi4hwvovt2smzhwexample
      requestBody:
        description: PUT /agreements/:agreement_id request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - allOf:
                                - type: object
                                  properties: {}
                                - type: object
                                  properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                          required: []
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    issuer:
                      type: object
                      properties:
                        name:
                          type: string
                          description: The name of the issuer
                          example: John Doe
                        email:
                          type: string
                          description: The email of the issuer. Will be used for communication if email
                            communication is enabled for the agreement.
                          example: john.doe@example.com
                        role:
                          type: string
                          enum:
                            - observer
                            - signer
                            - approver
                          description: The role of the issuer within the signing process.
                        locale:
                          type: string
                          enum:
                            - sv-SE
                            - en-US
                          default: sv-SE
                          description: Optional. The locale for the issuer of the signing process. Can be
                            overridden in the signing room, but the locale
                            provided by you will serve as the default in initial
                            communication. If not specified, the default locale
                            for the agreement will be used.
                      description: The issuer of the agreement. If not provided, the authenticated
                        client will be used.
                    send_emails:
                      type: boolean
                      description: Enables email communication in the agreement process. If not
                        provided, the default value is true. If disabled, you
                        will be responsible for handling all communication.
                    trust_level:
                      type: string
                      enum:
                        - SES
                        - AES
                        - QES
                      description: The minimum trust level used for all signatures in accordance with
                        the eIDAS regulation. If not provided, the default value
                        is SES.
                    signing_order:
                      type: boolean
                      description: Enables signing order for the agreement process. If not provided,
                        the default value is false. If enabled, the signers will
                        be required to sign in the order in which they are
                        defined.
                    theme:
                      oneOf:
                        - type: object
                          properties:
                            id:
                              type: string
                              format: cuid
                              description: The ID of the theme to use for the agreement.
                              example: cpe8jb8gohi7xpalaurexample
                          required:
                            - id
                        - type: object
                          properties:
                            disconnect:
                              type: boolean
                              enum:
                                - true
                              description: Disconnects the theme from the agreement.
                          required:
                            - disconnect
                    success_callback_url:
                      oneOf:
                        - type: string
                          format: url
                          description: An optional callback url to refer the participants back to post
                            taking successful action.
                          example: https://your-domain.com/sign-complete
                        - type: object
                          properties:
                            remove:
                              type: boolean
                              enum:
                                - true
                          required:
                            - remove
                    default_locale:
                      type: string
                      enum:
                        - sv-SE
                        - en-US
                      default: sv-SE
                      description: The default locale of the signing process. Can be overridden by
                        individual participants, but the default locale
                        determines the primary language used in  all
                        communication and UI.
                    lookup_key:
                      oneOf:
                        - type: string
                          description: Arbitrary string used to identify the agreement. Will be returned
                            in the metadata field of the agreement resource.
                          example: my-internal-customer-id
                        - type: object
                          properties:
                            remove:
                              type: boolean
                              enum:
                                - true
                          required:
                            - remove
                    automatic_reminders:
                      oneOf:
                        - type: string
                          enum:
                            - intense
                            - normal
                          description: The intensity of the reminders. The reminders are scheduled with an
                            exponential fall off, but the intensity regulates
                            the base interval. If expiration date is set for the
                            agreement, the reminders become more intense at the
                            end.
                        - type: object
                          properties:
                            remove:
                              type: boolean
                              enum:
                                - true
                          required:
                            - remove
                      description: Enables automatic reminders for all participants. Disabled by
                        default. If disabled, you can still manually send
                        reminders via the `/reminders` endpoint or via the
                        signing room.
                    mask_pii:
                      type: boolean
                      description: Whether to mask PII visually on the signed document. Default is
                        true. Note that this only affects the visual
                        representation of the PII, the actual PII is still
                        present in the evidence package or certificate.
                    expires_at:
                      oneOf:
                        - description: Set an expiration date for the signing process. The agreement will
                            be automatically marked as expired after this date
                            and won't be able to be signed. Time part of the
                            date will be ignored and set to 23:59:59:999 UTC.
                          type: string
                          format: date-time
                          pattern: ^\d{4}-\d{2}-\d{2}(T\d{2}:\d{2}:\d{2}(\.\d+)?)?Z?$
                          externalDocs:
                            url: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString
                        - type: object
                          properties:
                            remove:
                              type: boolean
                              enum:
                                - true
                          required:
                            - remove
                          description: If specifying this, it will remove the expiration date for the
                            agreement.
      security:
        - HTTP_1: []
    delete:
      operationId: DeleteAgreementsAgreementId
      responses:
        "200":
          description: DELETE /agreements/:agreement_id Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - deleted
                    description: Returns a single object of the agreement resource which was
                      deleted.
                  resource_type:
                    type: string
                    enum:
                      - agreement
                    description: Data contains the agreement resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the agreement
                        example: cckmmstwimwnfgqvuajexample
                      resource_type:
                        type: string
                        enum:
                          - agreement
                      test_mode:
                        type: boolean
                        description: Indicates if the agreement is created using a development client
                      status:
                        type: string
                        enum:
                          - draft
                          - pending
                          - fulfilled
                          - cancelled
                          - generating
                          - failed_to_generate
                          - open
                          - expired
                        description: The status of the agreement
                      trust_level:
                        type: string
                        enum:
                          - SES
                          - AES
                          - QES
                        description: The minimum trust level  for the signatures.
                      cancellation_reason:
                        nullable: true
                        type: string
                        description: If the agreement is in a cancelled state, this will be a short
                          description on the reason why, otherwise it will be
                          null.
                        example: null
                      theme:
                        oneOf:
                          - type: string
                            format: cuid
                            description: The unique identifier for the theme attached to the agreement
                            example: ccrirlws7dyjk2rzo2aexample
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - single
                                description: A single object of the theme resource.
                              resource_type:
                                type: string
                                enum:
                                  - theme
                                description: Data contains the theme resource.
                              data:
                                type: object
                                properties:
                                  id:
                                    type: string
                                    format: cuid
                                    description: The unique identifier of the theme
                                    example: coerir2amisfebqzdooexample
                                  resource_type:
                                    type: string
                                    enum:
                                      - theme
                                  logo:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                    description: The logo of the theme. This is displayed to the user in all
                                      communication and touch points.
                                  icon:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                    description: The icon of the theme. This is used for the favicon.
                                  primary_color:
                                    type: string
                                    default: "#000000"
                                    description: The primary color used to create the color palette in the signing
                                      room.
                                    example: "#000000"
                                  metadata:
                                    type: object
                                    properties:
                                      lookup_key:
                                        type: string
                                        description: A provided lookup key provided by you to help you identify the
                                          theme.
                                        example: your_internal_customer_id
                                    required:
                                      - lookup_key
                                  created_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                  updated_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                required:
                                  - id
                                  - resource_type
                                  - logo
                                  - icon
                                  - created_at
                                  - updated_at
                                description: The resource data.
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      issuer:
                        type: object
                        properties:
                          name:
                            nullable: true
                            type: string
                            description: The name of the issuer. Required if no email is provided.
                            example: John Doe
                          email:
                            nullable: true
                            type: string
                            description: The email of the issuer. Required if agreemnt is configured to send
                              emails.
                            example: example@example.com
                          role:
                            type: string
                            enum:
                              - signer
                              - approver
                              - observer
                            description: The role of the issuer in the agreement process.
                          participant_id:
                            type: string
                            format: cuid
                            description: If the issuer is a signer or approver this is the ID of the related
                              participant.
                            example: cd0jga4zijaebyga1wlexample
                          signing_room_url:
                            nullable: true
                            type: string
                            format: url
                            example: https://www.zigned.se/sign/cjecfacxrxzqd9def5zexample/cmakdfl6yfb9ls8h6jyexample
                            description: The URL to the signing room for the issuer. Only available after
                              the agreement has been finalized for signing.
                          locale:
                            nullable: true
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                            description: The locale for the issuer. Can be overridden from the signing room,
                              but this value serves as the default if nothing
                              else is specified. If omitted, the default_locale
                              of the agreement is used.
                        required:
                          - name
                          - email
                          - role
                          - signing_room_url
                        description: The issuer of the agreement
                      participants:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the participants belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the participant resource.
                              resource_type:
                                type: string
                                enum:
                                  - participant
                                description: Data contains the participant resource.
                              data:
                                $ref: "#/components/schemas/95c1af3f45da65daeedb661f70210b46b2bd71d5"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      observers:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the observers belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the observer resource.
                              resource_type:
                                type: string
                                enum:
                                  - observer
                                description: Data contains the observer resource.
                              data:
                                $ref: "#/components/schemas/c893c5c1d97a5bcbd8972ce188f48f8f75c6a171"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      signing_groups:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the signing groups belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the signing group resource.
                              resource_type:
                                type: string
                                enum:
                                  - signing_group
                                description: Data contains the signing group resource.
                              data:
                                $ref: "#/components/schemas/d69cfbd1e408327b80080ee78c087563df3370f4"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      documents:
                        type: object
                        properties:
                          original_documents:
                            type: object
                            properties:
                              main:
                                oneOf:
                                  - type: string
                                    format: cuid
                                    description: The unique identifier of the main document
                                    example: cmwqhs06osj0tus71kcexample
                                  - type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  - type: string
                                    nullable: true
                                    format: "null"
                                description: The main document which will be signed.
                              attachments:
                                oneOf:
                                  - type: array
                                    items:
                                      type: string
                                      format: cuid
                                      minLength: 1
                                    description: List of all IDs for the attachments belonging to this agreement
                                    example:
                                      - c5lnvzb9saw7pkusnvcexample
                                      - cgizx0nvpnyzxupx0cvexample
                                      - codqlu3eiigxia664m3example
                                  - type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the attachment resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - attachment
                                        description: Data contains the attachment resource.
                                      data:
                                        $ref: "#/components/schemas/18aea1f88c852890888d309ddd8605d8c0438d2b"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  - type: string
                                    nullable: true
                                    format: "null"
                            required:
                              - main
                          signed_document:
                            oneOf:
                              - type: string
                                format: cuid
                                description: The unique identifier for the signed document
                                example: ckfd2sygk12n9slxwkeexample
                              - type: object
                                properties:
                                  version:
                                    type: string
                                    enum:
                                      - "1.0"
                                    description: The version of the response schema
                                  result_type:
                                    type: string
                                    enum:
                                      - single
                                    description: A single object of the file resource.
                                  resource_type:
                                    type: string
                                    enum:
                                      - file
                                    description: Data contains the file resource.
                                  data:
                                    type: object
                                    properties:
                                      id:
                                        type: string
                                        format: cuid
                                        description: The unique identifier of the file
                                        example: cytp5m6ijs4rxs0erqsexample
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                      filename:
                                        type: string
                                        minLength: 1
                                        description: The complete filename including the file extension
                                        example: my-file.pdf
                                      mime_type:
                                        type: string
                                        minLength: 1
                                        description: The mime type of the file
                                        example: application/pdf
                                      url:
                                        type: string
                                        format: url
                                        description: The signed read url of the file
                                        example: https://zigned.se
                                      metadata:
                                        type: object
                                        properties:
                                          lookup_key:
                                            type: string
                                            description: A provided lookup key provided by you to help you identify the
                                              file.
                                            example: file_tag
                                        required:
                                          - lookup_key
                                      created_at:
                                        type: string
                                        description: UTC datetime ISO string
                                        example: 2024-01-01T00:00:00.000Z
                                      updated_at:
                                        type: string
                                        description: UTC datetime ISO string
                                        example: 2024-01-01T00:00:00.000Z
                                    required:
                                      - id
                                      - resource_type
                                      - filename
                                      - mime_type
                                      - created_at
                                      - updated_at
                                    description: The resource data.
                                required:
                                  - version
                                  - result_type
                                  - resource_type
                                  - data
                              - type: string
                                nullable: true
                                format: "null"
                            description: The finalized and signed document.
                        required:
                          - original_documents
                          - signed_document
                      signing_order:
                        type: object
                        properties:
                          enabled:
                            type: boolean
                          grouped:
                            type: boolean
                        required:
                          - enabled
                          - grouped
                      communication:
                        type: object
                        properties:
                          send_emails:
                            type: boolean
                          default_locale:
                            nullable: true
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                            description: The default locale for the agreement. Can be overridden by
                              individual participants/observers from the signing
                              room, but this value serves as the default if
                              nothing else is specified.
                          automatic_reminders:
                            type: object
                            properties:
                              enabled:
                                type: boolean
                              intensity:
                                nullable: true
                                type: string
                                enum:
                                  - intense
                                  - normal
                                description: The intensity of the reminders. The reminders are scheduled with an
                                  exponential fall off, but the intensity
                                  regulates the base interval. If expiration
                                  date is set for the agreement, the reminders
                                  become more intense at the end.
                            required:
                              - enabled
                              - intensity
                          recipient_messages:
                            nullable: true
                            type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - single
                                description: A single object of the recipient_message resource.
                              resource_type:
                                type: string
                                enum:
                                  - recipient_message
                                description: Data contains the recipient_message resource.
                              data:
                                type: object
                                properties:
                                  id:
                                    type: string
                                    format: cuid
                                    description: The unique identifier of the recipient message
                                    example: ck1ayqgg0fuxdetcvjtexample
                                  resource_type:
                                    type: string
                                    enum:
                                      - recipient_message
                                  message_templates:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the recipient message template resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - recipient_message_template
                                        description: Data contains the recipient message template resource.
                                      data:
                                        $ref: "#/components/schemas/7aadbd48657236af70d97541a9c85c00b14e95a5"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  message_template_variables:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the recipient message template variable
                                          resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - recipient_message_template_variable
                                        description: Data contains the recipient message template variable resource.
                                      data:
                                        $ref: "#/components/schemas/f9a847cbdf0e167d1aa8d3b7127afb96d878e823"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  created_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                  updated_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                required:
                                  - id
                                  - resource_type
                                  - message_templates
                                  - message_template_variables
                                  - created_at
                                  - updated_at
                                description: The resource data.
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                        required:
                          - send_emails
                      metadata:
                        type: object
                        properties:
                          mask_pii:
                            type: boolean
                            default: true
                            description: Whether to mask PII visually on the signed document. Default is
                              true. Note that this only affects the visual
                              representation of the PII, the actual PII is still
                              present in the evidence package or certificate.
                          lookup_key:
                            type: string
                            description: A provided lookup key provided by you to help you identify the
                              agreement.
                            example: your_internal_customer_id
                          success_callback_url:
                            type: string
                            format: url
                            description: A provided callback url to refer the participants back to post
                              successful action.
                            example: https://yourdomain.com/sign-complete
                      expires_at:
                        nullable: true
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      delete_scheduled_at:
                        nullable: true
                        type: string
                        description: The timestamp when deletion is scheduled to occur. Null if not
                          scheduled.
                        example: 2024-01-01T00:00:00.000Z
                      deleted_at:
                        nullable: true
                        type: string
                        description: The timestamp when the agreement was deleted. Null if not deleted.
                        example: 2024-01-01T00:00:00.000Z
                      deleted:
                        type: boolean
                        description: Whether the agreement has been deleted. Returns true if either
                          scheduled for deletion or if already deleted.
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - test_mode
                      - status
                      - cancellation_reason
                      - theme
                      - issuer
                      - participants
                      - signing_order
                      - communication
                      - updated_at
                      - created_at
                    description: The resource data that was deleted.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: DELETE /agreements/:agreement_id Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Deletes a single agreement. For API versions below 3.4.0, only
        draft agreements can be deleted. For fulfilled agreements, we will
        schedule deletion 30 days forward to ensure that all parties have had
        time to download a copy of the signed document. For other statuses we
        will schedule deletion immediately, but it can take up to 30 minutes
        before the deletion has been completed.
      summary: Delete an Agreement
      tags:
        - Agreements
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: DELETE /agreements/:agreement_id parameter
          schema:
            type: string
            format: cuid
            example: cdzwzi4hwvovt2smzhwexample
      security:
        - HTTP_1: []
  /agreements/{agreement_id}/cancel-deletion:
    post:
      operationId: PostAgreementsAgreementIdCancelDeletion
      responses:
        "200":
          description: POST /agreements/:agreement_id/cancel-deletion Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the agreement resource.
                  resource_type:
                    type: string
                    enum:
                      - agreement
                    description: Data contains the agreement resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the agreement
                        example: cckmmstwimwnfgqvuajexample
                      resource_type:
                        type: string
                        enum:
                          - agreement
                      test_mode:
                        type: boolean
                        description: Indicates if the agreement is created using a development client
                      status:
                        type: string
                        enum:
                          - draft
                          - pending
                          - fulfilled
                          - cancelled
                          - generating
                          - failed_to_generate
                          - open
                          - expired
                        description: The status of the agreement
                      trust_level:
                        type: string
                        enum:
                          - SES
                          - AES
                          - QES
                        description: The minimum trust level  for the signatures.
                      cancellation_reason:
                        nullable: true
                        type: string
                        description: If the agreement is in a cancelled state, this will be a short
                          description on the reason why, otherwise it will be
                          null.
                        example: null
                      theme:
                        oneOf:
                          - type: string
                            format: cuid
                            description: The unique identifier for the theme attached to the agreement
                            example: ccrirlws7dyjk2rzo2aexample
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - single
                                description: A single object of the theme resource.
                              resource_type:
                                type: string
                                enum:
                                  - theme
                                description: Data contains the theme resource.
                              data:
                                type: object
                                properties:
                                  id:
                                    type: string
                                    format: cuid
                                    description: The unique identifier of the theme
                                    example: coerir2amisfebqzdooexample
                                  resource_type:
                                    type: string
                                    enum:
                                      - theme
                                  logo:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                    description: The logo of the theme. This is displayed to the user in all
                                      communication and touch points.
                                  icon:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                    description: The icon of the theme. This is used for the favicon.
                                  primary_color:
                                    type: string
                                    default: "#000000"
                                    description: The primary color used to create the color palette in the signing
                                      room.
                                    example: "#000000"
                                  metadata:
                                    type: object
                                    properties:
                                      lookup_key:
                                        type: string
                                        description: A provided lookup key provided by you to help you identify the
                                          theme.
                                        example: your_internal_customer_id
                                    required:
                                      - lookup_key
                                  created_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                  updated_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                required:
                                  - id
                                  - resource_type
                                  - logo
                                  - icon
                                  - created_at
                                  - updated_at
                                description: The resource data.
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      issuer:
                        type: object
                        properties:
                          name:
                            nullable: true
                            type: string
                            description: The name of the issuer. Required if no email is provided.
                            example: John Doe
                          email:
                            nullable: true
                            type: string
                            description: The email of the issuer. Required if agreemnt is configured to send
                              emails.
                            example: example@example.com
                          role:
                            type: string
                            enum:
                              - signer
                              - approver
                              - observer
                            description: The role of the issuer in the agreement process.
                          participant_id:
                            type: string
                            format: cuid
                            description: If the issuer is a signer or approver this is the ID of the related
                              participant.
                            example: cd0jga4zijaebyga1wlexample
                          signing_room_url:
                            nullable: true
                            type: string
                            format: url
                            example: https://www.zigned.se/sign/cjecfacxrxzqd9def5zexample/cmakdfl6yfb9ls8h6jyexample
                            description: The URL to the signing room for the issuer. Only available after
                              the agreement has been finalized for signing.
                          locale:
                            nullable: true
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                            description: The locale for the issuer. Can be overridden from the signing room,
                              but this value serves as the default if nothing
                              else is specified. If omitted, the default_locale
                              of the agreement is used.
                        required:
                          - name
                          - email
                          - role
                          - signing_room_url
                        description: The issuer of the agreement
                      participants:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the participants belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the participant resource.
                              resource_type:
                                type: string
                                enum:
                                  - participant
                                description: Data contains the participant resource.
                              data:
                                $ref: "#/components/schemas/95c1af3f45da65daeedb661f70210b46b2bd71d5"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      observers:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the observers belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the observer resource.
                              resource_type:
                                type: string
                                enum:
                                  - observer
                                description: Data contains the observer resource.
                              data:
                                $ref: "#/components/schemas/c893c5c1d97a5bcbd8972ce188f48f8f75c6a171"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      signing_groups:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the signing groups belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the signing group resource.
                              resource_type:
                                type: string
                                enum:
                                  - signing_group
                                description: Data contains the signing group resource.
                              data:
                                $ref: "#/components/schemas/d69cfbd1e408327b80080ee78c087563df3370f4"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      documents:
                        type: object
                        properties:
                          original_documents:
                            type: object
                            properties:
                              main:
                                oneOf:
                                  - type: string
                                    format: cuid
                                    description: The unique identifier of the main document
                                    example: cmwqhs06osj0tus71kcexample
                                  - type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  - type: string
                                    nullable: true
                                    format: "null"
                                description: The main document which will be signed.
                              attachments:
                                oneOf:
                                  - type: array
                                    items:
                                      type: string
                                      format: cuid
                                      minLength: 1
                                    description: List of all IDs for the attachments belonging to this agreement
                                    example:
                                      - c5lnvzb9saw7pkusnvcexample
                                      - cgizx0nvpnyzxupx0cvexample
                                      - codqlu3eiigxia664m3example
                                  - type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the attachment resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - attachment
                                        description: Data contains the attachment resource.
                                      data:
                                        $ref: "#/components/schemas/18aea1f88c852890888d309ddd8605d8c0438d2b"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  - type: string
                                    nullable: true
                                    format: "null"
                            required:
                              - main
                          signed_document:
                            oneOf:
                              - type: string
                                format: cuid
                                description: The unique identifier for the signed document
                                example: ckfd2sygk12n9slxwkeexample
                              - type: object
                                properties:
                                  version:
                                    type: string
                                    enum:
                                      - "1.0"
                                    description: The version of the response schema
                                  result_type:
                                    type: string
                                    enum:
                                      - single
                                    description: A single object of the file resource.
                                  resource_type:
                                    type: string
                                    enum:
                                      - file
                                    description: Data contains the file resource.
                                  data:
                                    type: object
                                    properties:
                                      id:
                                        type: string
                                        format: cuid
                                        description: The unique identifier of the file
                                        example: cytp5m6ijs4rxs0erqsexample
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                      filename:
                                        type: string
                                        minLength: 1
                                        description: The complete filename including the file extension
                                        example: my-file.pdf
                                      mime_type:
                                        type: string
                                        minLength: 1
                                        description: The mime type of the file
                                        example: application/pdf
                                      url:
                                        type: string
                                        format: url
                                        description: The signed read url of the file
                                        example: https://zigned.se
                                      metadata:
                                        type: object
                                        properties:
                                          lookup_key:
                                            type: string
                                            description: A provided lookup key provided by you to help you identify the
                                              file.
                                            example: file_tag
                                        required:
                                          - lookup_key
                                      created_at:
                                        type: string
                                        description: UTC datetime ISO string
                                        example: 2024-01-01T00:00:00.000Z
                                      updated_at:
                                        type: string
                                        description: UTC datetime ISO string
                                        example: 2024-01-01T00:00:00.000Z
                                    required:
                                      - id
                                      - resource_type
                                      - filename
                                      - mime_type
                                      - created_at
                                      - updated_at
                                    description: The resource data.
                                required:
                                  - version
                                  - result_type
                                  - resource_type
                                  - data
                              - type: string
                                nullable: true
                                format: "null"
                            description: The finalized and signed document.
                        required:
                          - original_documents
                          - signed_document
                      signing_order:
                        type: object
                        properties:
                          enabled:
                            type: boolean
                          grouped:
                            type: boolean
                        required:
                          - enabled
                          - grouped
                      communication:
                        type: object
                        properties:
                          send_emails:
                            type: boolean
                          default_locale:
                            nullable: true
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                            description: The default locale for the agreement. Can be overridden by
                              individual participants/observers from the signing
                              room, but this value serves as the default if
                              nothing else is specified.
                          automatic_reminders:
                            type: object
                            properties:
                              enabled:
                                type: boolean
                              intensity:
                                nullable: true
                                type: string
                                enum:
                                  - intense
                                  - normal
                                description: The intensity of the reminders. The reminders are scheduled with an
                                  exponential fall off, but the intensity
                                  regulates the base interval. If expiration
                                  date is set for the agreement, the reminders
                                  become more intense at the end.
                            required:
                              - enabled
                              - intensity
                          recipient_messages:
                            nullable: true
                            type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - single
                                description: A single object of the recipient_message resource.
                              resource_type:
                                type: string
                                enum:
                                  - recipient_message
                                description: Data contains the recipient_message resource.
                              data:
                                type: object
                                properties:
                                  id:
                                    type: string
                                    format: cuid
                                    description: The unique identifier of the recipient message
                                    example: ck1ayqgg0fuxdetcvjtexample
                                  resource_type:
                                    type: string
                                    enum:
                                      - recipient_message
                                  message_templates:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the recipient message template resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - recipient_message_template
                                        description: Data contains the recipient message template resource.
                                      data:
                                        $ref: "#/components/schemas/7aadbd48657236af70d97541a9c85c00b14e95a5"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  message_template_variables:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the recipient message template variable
                                          resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - recipient_message_template_variable
                                        description: Data contains the recipient message template variable resource.
                                      data:
                                        $ref: "#/components/schemas/f9a847cbdf0e167d1aa8d3b7127afb96d878e823"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  created_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                  updated_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                required:
                                  - id
                                  - resource_type
                                  - message_templates
                                  - message_template_variables
                                  - created_at
                                  - updated_at
                                description: The resource data.
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                        required:
                          - send_emails
                      metadata:
                        type: object
                        properties:
                          mask_pii:
                            type: boolean
                            default: true
                            description: Whether to mask PII visually on the signed document. Default is
                              true. Note that this only affects the visual
                              representation of the PII, the actual PII is still
                              present in the evidence package or certificate.
                          lookup_key:
                            type: string
                            description: A provided lookup key provided by you to help you identify the
                              agreement.
                            example: your_internal_customer_id
                          success_callback_url:
                            type: string
                            format: url
                            description: A provided callback url to refer the participants back to post
                              successful action.
                            example: https://yourdomain.com/sign-complete
                      expires_at:
                        nullable: true
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      delete_scheduled_at:
                        nullable: true
                        type: string
                        description: The timestamp when deletion is scheduled to occur. Null if not
                          scheduled.
                        example: 2024-01-01T00:00:00.000Z
                      deleted_at:
                        nullable: true
                        type: string
                        description: The timestamp when the agreement was deleted. Null if not deleted.
                        example: 2024-01-01T00:00:00.000Z
                      deleted:
                        type: boolean
                        description: Whether the agreement has been deleted. Returns true if either
                          scheduled for deletion or if already deleted.
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - test_mode
                      - status
                      - cancellation_reason
                      - theme
                      - issuer
                      - participants
                      - signing_order
                      - communication
                      - updated_at
                      - created_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: POST /agreements/:agreement_id/cancel-deletion Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Cancels a scheduled deletion for an agreement. Only works if the
        agreement has a delete_scheduled_at timestamp and has not yet been
        deleted.
      summary: Cancel Scheduled Deletion
      tags:
        - Agreements
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: POST /agreements/:agreement_id/cancel-deletion parameter
          schema:
            type: string
            format: cuid
            example: cdzwzi4hwvovt2smzhwexample
      requestBody:
        description: POST /agreements/:agreement_id/cancel-deletion request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - type: object
                              properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                    - type: object
                      properties: {}
                      required: []
                - type: object
                  properties: {}
      security:
        - HTTP_1: []
  /agreements/{agreement_id}/events:
    get:
      operationId: GetAgreementsAgreementIdEvents
      responses:
        "200":
          description: GET /agreements/:agreement_id/events Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - list
                    description: A non-paginated list of the agreement event resource.
                  resource_type:
                    type: string
                    enum:
                      - agreement_event
                    description: Data contains the agreement event resource.
                  data:
                    $ref: "#/components/schemas/a3c0a57c88c3f5431a04cced7bd35e9fc77a12bb"
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: GET /agreements/:agreement_id/events Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Lists all events for the agreement (excluding specific events
        related to participants). The events are returned in ascending order by
        creation date. Events are read only.
      summary: List Agreement Events
      tags:
        - Agreements
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: GET /agreements/:agreement_id/events parameter
          schema:
            type: string
            format: cuid
            example: cdsfariwnujeawtus9kexample
      security:
        - HTTP_1: []
  /agreements/{agreement_id}/participants:
    post:
      operationId: PostAgreementsAgreementIdParticipants
      responses:
        "200":
          description: POST /agreements/:agreement_id/participants Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the participant resource.
                  resource_type:
                    type: string
                    enum:
                      - participant
                    description: Data contains the participant resource.
                  data:
                    allOf:
                      - type: object
                        properties:
                          id:
                            type: string
                            format: cuid
                            description: The unique identifier of the participant
                            example: c7uwzf2hygix6pmzsh5example
                          resource_type:
                            type: string
                            enum:
                              - participant
                          name:
                            nullable: true
                            type: string
                            description: The name of the participant. Required if no email is provided.
                            example: Jane Doe
                          email:
                            nullable: true
                            type: string
                            description: The email of the participant. Required if agreemnt is configured to
                              send emails.
                            example: jane.doe@example.com
                          status:
                            type: string
                            enum:
                              - draft
                              - pending
                              - initiated
                              - processing
                              - fulfilled
                              - rejected
                            description: The status of the participant
                          order:
                            nullable: true
                            type: number
                            format: double
                            minimum: 0
                            exclusiveMinimum: true
                            maximum: 1.7976931348623157e+308
                            exclusiveMaximum: false
                            description: The queue number of the participant (if sequential signing order is
                              enabled)
                            example: 1
                          signing_group:
                            oneOf:
                              - type: string
                                format: cuid
                                description: The unique identifier for the signing groups
                                example: cgbzlzelirbjrjq0xrxexample
                              - $ref: "#/components/schemas/118cb3b11b8a1f3b6b1e60a89f96a8be9da32a0f"
                              - type: string
                                nullable: true
                                format: "null"
                          agreement:
                            type: string
                            format: cuid
                            description: The unique identifier for the agreement this participant belongs to
                            example: cj2orx6w6iqpscuqsieexample
                          signing_room_url:
                            nullable: true
                            type: string
                            format: url
                            example: https://www.zigned.se/sign/cjecfacxrxzqd9def5zexample/cmakdfl6yfb9ls8h6jyexample
                            description: The URL to the signing room for the participant. Only available
                              after the agreement has been finalized for
                              signing.
                          locale:
                            nullable: true
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                            description: The locale for the participant. Can be overridden from the signing
                              room, but this value serves as the default if
                              nothing else is specified.
                          created_at:
                            type: string
                            description: UTC datetime ISO string
                            example: 2024-01-01T00:00:00.000Z
                          updated_at:
                            type: string
                            description: UTC datetime ISO string
                            example: 2024-01-01T00:00:00.000Z
                        required:
                          - id
                          - resource_type
                          - name
                          - email
                          - status
                          - order
                          - signing_group
                          - agreement
                          - signing_room_url
                          - created_at
                          - updated_at
                        description: The participant resource
                      - discriminator:
                          propertyName: role
                        oneOf:
                          - type: object
                            properties:
                              role:
                                type: string
                                enum:
                                  - approver
                                description: The role of the participant
                              decision_made_at:
                                nullable: true
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                            required:
                              - role
                              - decision_made_at
                          - type: object
                            properties:
                              role:
                                type: string
                                enum:
                                  - signer
                                description: The role of the participant
                              signed_at:
                                nullable: true
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                              signature:
                                nullable: true
                                oneOf:
                                  - allOf:
                                      - type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the signature data
                                            example: cqdax9rdsuqyvtgemlzexample
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - created_at
                                          - updated_at
                                      - discriminator:
                                          propertyName: method
                                        oneOf:
                                          - type: object
                                            properties:
                                              method:
                                                type: string
                                                enum:
                                                  - se_bid
                                                description: The method used for signing
                                              data:
                                                type: object
                                                properties:
                                                  name:
                                                    nullable: true
                                                    type: string
                                                    description: The full name of the signer returned by Mobile Swedish BankID
                                                    example: Jane Doe
                                                  user_message:
                                                    type: string
                                                    description: The message presented to the user in the Mobile BankID application
                                                      when signing
                                                    example: I have read and understood the contents of the document example.pdf and
                                                      I hereby approve
                                                      everything in it.
                                                  document_hash:
                                                    type: string
                                                    description: The SHA256 hash of the document to be signed (Base64 encoded)
                                                    example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                  status:
                                                    type: string
                                                    enum:
                                                      - complete
                                                      - error
                                                      - failed
                                                      - draft
                                                      - pending
                                                      - initializing
                                                      - cancelled
                                                    description: The status for the Swedish BankID signing process
                                                required:
                                                  - name
                                                  - user_message
                                                  - document_hash
                                                  - status
                                                description: Summary of the BankID signature data
                                            required:
                                              - method
                                              - data
                                          - type: object
                                            properties:
                                              method:
                                                type: string
                                                enum:
                                                  - verification_code
                                                description: The method used for signing
                                              data:
                                                type: object
                                                properties:
                                                  email:
                                                    nullable: true
                                                    type: string
                                                    description: The email used for the verification code
                                                    example: john.doe@example.com
                                                  name:
                                                    nullable: true
                                                    type: string
                                                    description: The name of the signer
                                                    example: John Doe
                                                  user_message:
                                                    type: string
                                                    description: The message presented to the user when signing
                                                    example: I have read and understood the contents of the document example.pdf and
                                                      I hereby approve
                                                      everything in it.
                                                  document_hash:
                                                    type: string
                                                    description: The SHA256 hash of the document to be signed (Base64 encoded)
                                                    example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                  status:
                                                    type: string
                                                    enum:
                                                      - confirmed
                                                      - draft
                                                      - pending
                                                      - confirmation_failed
                                                      - unable_to_send
                                                      - expired
                                                      - cancelled
                                                    description: The status of the verification code signing process
                                                required:
                                                  - email
                                                  - name
                                                  - user_message
                                                  - document_hash
                                                  - status
                                                description: Summary of the verification code signature data
                                            required:
                                              - method
                                              - data
                                          - type: object
                                            properties:
                                              method:
                                                type: string
                                                enum:
                                                  - truid
                                                description: The method used for signing
                                              data:
                                                type: object
                                                properties:
                                                  given_name:
                                                    nullable: true
                                                    type: string
                                                    description: The given name of the signer returned by Truid
                                                    example: Jane
                                                  family_name:
                                                    nullable: true
                                                    type: string
                                                    description: The family name of the signer returned by Truid
                                                    example: Doe
                                                  legal_name:
                                                    nullable: true
                                                    type: string
                                                    description: The legal name of the signer returned by Truid
                                                    example: Jane Doe
                                                  user_message:
                                                    type: string
                                                    description: The message presented to the user in the Truid application when
                                                      signing
                                                    example: I have read and wish to sign the document.
                                                  document_hash:
                                                    type: string
                                                    description: The SHA256 hash of the document to be signed (Base64 encoded)
                                                    example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                  status:
                                                    type: string
                                                    enum:
                                                      - draft
                                                      - pending
                                                      - fulfilled
                                                      - failed
                                                    description: The status for the Truid signing process
                                                required:
                                                  - given_name
                                                  - family_name
                                                  - legal_name
                                                  - user_message
                                                  - document_hash
                                                  - status
                                                description: Summary of the Truid signature data
                                            required:
                                              - method
                                              - data
                                          - type: object
                                            properties:
                                              method:
                                                type: string
                                                enum:
                                                  - zealid
                                                description: The method used for signing
                                              data:
                                                type: object
                                                properties:
                                                  givenname:
                                                    nullable: true
                                                    type: string
                                                    description: The given name of the signer as specified in the signing
                                                      certificate
                                                    example: Jane
                                                  surname:
                                                    nullable: true
                                                    type: string
                                                    description: The surname of the signer as specified in the signing certificate
                                                    example: Doe
                                                  country:
                                                    nullable: true
                                                    type: string
                                                    description: The country of the signer as specified in the signing certificate
                                                    example: SE
                                                  identifier:
                                                    nullable: true
                                                    type: string
                                                    description: The primary identifier, such as a Swedish Personal Number, as
                                                      specified in the signing
                                                      certificate
                                                    example: SE
                                                  signing_certificate:
                                                    nullable: true
                                                    type: string
                                                    description: The signing certificate for the signatory, returned by ZealID
                                                    example: >-
                                                      --BEGIN CERTIFICATE--

                                                      [BASE64 ENCODED
                                                      CERTIFICATE]

                                                      --END CERTIFICATE--
                                                  document_hash:
                                                    type: string
                                                    description: The SHA256 hash of the data to be signed (Base64 encoded)
                                                    example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                  status:
                                                    type: string
                                                    enum:
                                                      - draft
                                                      - awaiting_authentication
                                                      - awaiting_sign
                                                      - complete
                                                      - failed
                                                    description: The status for the ZealID signing process
                                                required:
                                                  - givenname
                                                  - surname
                                                  - country
                                                  - identifier
                                                  - signing_certificate
                                                  - document_hash
                                                  - status
                                                description: Summary of the ZealID signature data
                                            required:
                                              - method
                                              - data
                                  - type: object
                                    properties:
                                      method:
                                        type: string
                                        nullable: true
                                        format: "null"
                                      data:
                                        type: string
                                        nullable: true
                                        format: "null"
                                    required:
                                      - method
                                      - data
                                description: The signature data for the participant
                              identity_enforcement:
                                discriminator:
                                  propertyName: enabled
                                oneOf:
                                  - type: object
                                    properties:
                                      enabled:
                                        type: boolean
                                        enum:
                                          - true
                                        description: If true, identity enforcement is enabled for the participant
                                      status:
                                        type: string
                                        enum:
                                          - pending
                                          - passed
                                          - failed
                                        description: The status of the identity enforcement
                                      enforcement_method:
                                        type: string
                                        enum:
                                          - swe_pno_crosscheck
                                        description: The enforcement method for the identity. Depending on which method
                                          is used, different signature method
                                          are available
                                    required:
                                      - enabled
                                      - status
                                      - enforcement_method
                                  - type: object
                                    properties:
                                      enabled:
                                        type: boolean
                                        enum:
                                          - false
                                        description: If true, identity enforcement is enabled for the participant
                                      status:
                                        type: string
                                        nullable: true
                                        format: "null"
                                      enforcement_method:
                                        type: string
                                        nullable: true
                                        format: "null"
                                    required:
                                      - enabled
                                      - status
                                      - enforcement_method
                            required:
                              - role
                              - signed_at
                              - signature
                              - identity_enforcement
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: POST /agreements/:agreement_id/participants Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Creates a new participant in draft status. Use the participant ID
        in subsequent requests.
      summary: Create a Participant
      tags:
        - Agreements
        - Participants
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: POST /agreements/:agreement_id/participants parameter
          schema:
            type: string
            format: cuid
            example: cl8oeabwmzdirlpjpp8example
      requestBody:
        description: POST /agreements/:agreement_id/participants request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - allOf:
                                - type: object
                                  properties: {}
                                - type: object
                                  properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                          required: []
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    email:
                      type: string
                      description: The email of the participant. Will be used in all communication, if
                        email communication is enabled for the agreement.
                    name:
                      type: string
                      description: The name of the participant. If omitted, the email adress will be
                        used as name.
                    role:
                      type: string
                      enum:
                        - signer
                        - approver
                      default: signer
                      description: The role of the participant within the signing process. If the
                        agreement is configured for qualified signatures, only
                        "signer" is supported. Default role is "signer".
                    personal_number:
                      type: string
                      description: The personal number of the participant. If provided, the signer
                        will have to use an advanced signing method that
                        supports a swedish personal number to sign the agreement
                        and only be allowed to sign if the personal number
                        matches what is provided. Only available for signers.
                    locale:
                      type: string
                      enum:
                        - sv-SE
                        - en-US
                      default: sv-SE
                      description: Optional. The locale for the participant. Can be overridden by the
                        participant when signing, but the locale provided by you
                        will serve as the default in initial communication. If
                        not specified, the default locale for the agreement will
                        be used.
                    order:
                      type: integer
                      format: int64
                      minimum: -9007199254740991
                      exclusiveMinimum: false
                      maximum: 9007199254740991
                      exclusiveMaximum: false
                      description: Only applicable if signing order is enabled for the agreement. It
                        specifies the order in the signing queue this
                        participant will have. Will be put last in line if not
                        specified. If multiple participants share the same queue
                        number, this participant will take precendent and the
                        rest will be moved forward accordingly.
                  required: []
      security:
        - HTTP_1: []
    get:
      operationId: GetAgreementsAgreementIdParticipants
      responses:
        "200":
          description: GET /agreements/:agreement_id/participants Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - list
                    description: A non-paginated list of the participant resource.
                  resource_type:
                    type: string
                    enum:
                      - participant
                    description: Data contains the participant resource.
                  data:
                    $ref: "#/components/schemas/95c1af3f45da65daeedb661f70210b46b2bd71d5"
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: GET /agreements/:agreement_id/participants Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Lists all participants for the agreement. The participants are
        returned in the order they were created or, if signing order is enabled,
        the order that is defined.
      summary: List Participants
      tags:
        - Agreements
        - Participants
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: GET /agreements/:agreement_id/participants parameter
          schema:
            type: string
            format: cuid
            example: cdgsjjksqmaymnqcemhexample
      security:
        - HTTP_1: []
  /agreements/{agreement_id}/participants/batch:
    post:
      operationId: PostAgreementsAgreementIdParticipantsBatch
      responses:
        "200":
          description: POST /agreements/:agreement_id/participants/batch Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - list
                    description: A non-paginated list of the participant resource.
                  resource_type:
                    type: string
                    enum:
                      - participant
                    description: Data contains the participant resource.
                  data:
                    $ref: "#/components/schemas/95c1af3f45da65daeedb661f70210b46b2bd71d5"
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: POST /agreements/:agreement_id/participants/batch Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Batch creates new participants in draft status. Use the participant
        IDs in subsequent requests.
      summary: Batch create participants
      tags:
        - Agreements
        - Participants
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: POST /agreements/:agreement_id/participants/batch parameter
          schema:
            type: string
            format: cuid
            example: cdkakpcbyhz8kgqjh4qexample
      requestBody:
        description: POST /agreements/:agreement_id/participants/batch request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - allOf:
                                - type: object
                                  properties: {}
                                - type: object
                                  properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                          required: []
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    participants:
                      type: array
                      items:
                        type: object
                        properties:
                          email:
                            type: string
                            description: The email of the participant. Will be used in all communication, if
                              email communication is enabled for the agreement.
                          name:
                            type: string
                            description: The name of the participant. If omitted, the email adress will be
                              used as name.
                          role:
                            type: string
                            enum:
                              - signer
                              - approver
                            default: signer
                            description: The role of the participant within the signing process. If the
                              agreement is configured for qualified signatures,
                              only "signer" is supported. Default role is
                              "signer".
                          personal_number:
                            type: string
                            description: The personal number of the participant. If provided, the signer
                              will have to use an advanced signing method that
                              supports a swedish personal number to sign the
                              agreement and only be allowed to sign if the
                              personal number matches what is provided. Only
                              available for signers.
                          locale:
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                            default: sv-SE
                            description: Optional. The locale for the participant. Can be overridden by the
                              participant when signing, but the locale provided
                              by you will serve as the default in initial
                              communication. If not specified, the default
                              locale for the agreement will be used.
                          order:
                            type: integer
                            format: int64
                            minimum: -9007199254740991
                            exclusiveMinimum: false
                            maximum: 9007199254740991
                            exclusiveMaximum: false
                            description: Only applicable if signing order is enabled for the agreement. It
                              specifies the order in the signing queue this
                              participant will have. Will be put last in line if
                              not specified. If multiple participants share the
                              same queue number, this participant will take
                              precendent and the rest will be moved forward
                              accordingly.
                  required:
                    - participants
      security:
        - HTTP_1: []
  /agreements/{agreement_id}/participants/{participant_id}:
    put:
      operationId: PutAgreementsAgreementIdParticipantsParticipantId
      responses:
        "200":
          description: PUT /agreements/:agreement_id/participants/:participant_id
            Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the participant resource.
                  resource_type:
                    type: string
                    enum:
                      - participant
                    description: Data contains the participant resource.
                  data:
                    allOf:
                      - type: object
                        properties:
                          id:
                            type: string
                            format: cuid
                            description: The unique identifier of the participant
                            example: c7uwzf2hygix6pmzsh5example
                          resource_type:
                            type: string
                            enum:
                              - participant
                          name:
                            nullable: true
                            type: string
                            description: The name of the participant. Required if no email is provided.
                            example: Jane Doe
                          email:
                            nullable: true
                            type: string
                            description: The email of the participant. Required if agreemnt is configured to
                              send emails.
                            example: jane.doe@example.com
                          status:
                            type: string
                            enum:
                              - draft
                              - pending
                              - initiated
                              - processing
                              - fulfilled
                              - rejected
                            description: The status of the participant
                          order:
                            nullable: true
                            type: number
                            format: double
                            minimum: 0
                            exclusiveMinimum: true
                            maximum: 1.7976931348623157e+308
                            exclusiveMaximum: false
                            description: The queue number of the participant (if sequential signing order is
                              enabled)
                            example: 1
                          signing_group:
                            oneOf:
                              - type: string
                                format: cuid
                                description: The unique identifier for the signing groups
                                example: cgbzlzelirbjrjq0xrxexample
                              - $ref: "#/components/schemas/118cb3b11b8a1f3b6b1e60a89f96a8be9da32a0f"
                              - type: string
                                nullable: true
                                format: "null"
                          agreement:
                            type: string
                            format: cuid
                            description: The unique identifier for the agreement this participant belongs to
                            example: cj2orx6w6iqpscuqsieexample
                          signing_room_url:
                            nullable: true
                            type: string
                            format: url
                            example: https://www.zigned.se/sign/cjecfacxrxzqd9def5zexample/cmakdfl6yfb9ls8h6jyexample
                            description: The URL to the signing room for the participant. Only available
                              after the agreement has been finalized for
                              signing.
                          locale:
                            nullable: true
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                            description: The locale for the participant. Can be overridden from the signing
                              room, but this value serves as the default if
                              nothing else is specified.
                          created_at:
                            type: string
                            description: UTC datetime ISO string
                            example: 2024-01-01T00:00:00.000Z
                          updated_at:
                            type: string
                            description: UTC datetime ISO string
                            example: 2024-01-01T00:00:00.000Z
                        required:
                          - id
                          - resource_type
                          - name
                          - email
                          - status
                          - order
                          - signing_group
                          - agreement
                          - signing_room_url
                          - created_at
                          - updated_at
                        description: The participant resource
                      - discriminator:
                          propertyName: role
                        oneOf:
                          - type: object
                            properties:
                              role:
                                type: string
                                enum:
                                  - approver
                                description: The role of the participant
                              decision_made_at:
                                nullable: true
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                            required:
                              - role
                              - decision_made_at
                          - type: object
                            properties:
                              role:
                                type: string
                                enum:
                                  - signer
                                description: The role of the participant
                              signed_at:
                                nullable: true
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                              signature:
                                nullable: true
                                oneOf:
                                  - allOf:
                                      - type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the signature data
                                            example: cqdax9rdsuqyvtgemlzexample
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - created_at
                                          - updated_at
                                      - discriminator:
                                          propertyName: method
                                        oneOf:
                                          - type: object
                                            properties:
                                              method:
                                                type: string
                                                enum:
                                                  - se_bid
                                                description: The method used for signing
                                              data:
                                                type: object
                                                properties:
                                                  name:
                                                    nullable: true
                                                    type: string
                                                    description: The full name of the signer returned by Mobile Swedish BankID
                                                    example: Jane Doe
                                                  user_message:
                                                    type: string
                                                    description: The message presented to the user in the Mobile BankID application
                                                      when signing
                                                    example: I have read and understood the contents of the document example.pdf and
                                                      I hereby approve
                                                      everything in it.
                                                  document_hash:
                                                    type: string
                                                    description: The SHA256 hash of the document to be signed (Base64 encoded)
                                                    example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                  status:
                                                    type: string
                                                    enum:
                                                      - complete
                                                      - error
                                                      - failed
                                                      - draft
                                                      - pending
                                                      - initializing
                                                      - cancelled
                                                    description: The status for the Swedish BankID signing process
                                                required:
                                                  - name
                                                  - user_message
                                                  - document_hash
                                                  - status
                                                description: Summary of the BankID signature data
                                            required:
                                              - method
                                              - data
                                          - type: object
                                            properties:
                                              method:
                                                type: string
                                                enum:
                                                  - verification_code
                                                description: The method used for signing
                                              data:
                                                type: object
                                                properties:
                                                  email:
                                                    nullable: true
                                                    type: string
                                                    description: The email used for the verification code
                                                    example: john.doe@example.com
                                                  name:
                                                    nullable: true
                                                    type: string
                                                    description: The name of the signer
                                                    example: John Doe
                                                  user_message:
                                                    type: string
                                                    description: The message presented to the user when signing
                                                    example: I have read and understood the contents of the document example.pdf and
                                                      I hereby approve
                                                      everything in it.
                                                  document_hash:
                                                    type: string
                                                    description: The SHA256 hash of the document to be signed (Base64 encoded)
                                                    example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                  status:
                                                    type: string
                                                    enum:
                                                      - confirmed
                                                      - draft
                                                      - pending
                                                      - confirmation_failed
                                                      - unable_to_send
                                                      - expired
                                                      - cancelled
                                                    description: The status of the verification code signing process
                                                required:
                                                  - email
                                                  - name
                                                  - user_message
                                                  - document_hash
                                                  - status
                                                description: Summary of the verification code signature data
                                            required:
                                              - method
                                              - data
                                          - type: object
                                            properties:
                                              method:
                                                type: string
                                                enum:
                                                  - truid
                                                description: The method used for signing
                                              data:
                                                type: object
                                                properties:
                                                  given_name:
                                                    nullable: true
                                                    type: string
                                                    description: The given name of the signer returned by Truid
                                                    example: Jane
                                                  family_name:
                                                    nullable: true
                                                    type: string
                                                    description: The family name of the signer returned by Truid
                                                    example: Doe
                                                  legal_name:
                                                    nullable: true
                                                    type: string
                                                    description: The legal name of the signer returned by Truid
                                                    example: Jane Doe
                                                  user_message:
                                                    type: string
                                                    description: The message presented to the user in the Truid application when
                                                      signing
                                                    example: I have read and wish to sign the document.
                                                  document_hash:
                                                    type: string
                                                    description: The SHA256 hash of the document to be signed (Base64 encoded)
                                                    example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                  status:
                                                    type: string
                                                    enum:
                                                      - draft
                                                      - pending
                                                      - fulfilled
                                                      - failed
                                                    description: The status for the Truid signing process
                                                required:
                                                  - given_name
                                                  - family_name
                                                  - legal_name
                                                  - user_message
                                                  - document_hash
                                                  - status
                                                description: Summary of the Truid signature data
                                            required:
                                              - method
                                              - data
                                          - type: object
                                            properties:
                                              method:
                                                type: string
                                                enum:
                                                  - zealid
                                                description: The method used for signing
                                              data:
                                                type: object
                                                properties:
                                                  givenname:
                                                    nullable: true
                                                    type: string
                                                    description: The given name of the signer as specified in the signing
                                                      certificate
                                                    example: Jane
                                                  surname:
                                                    nullable: true
                                                    type: string
                                                    description: The surname of the signer as specified in the signing certificate
                                                    example: Doe
                                                  country:
                                                    nullable: true
                                                    type: string
                                                    description: The country of the signer as specified in the signing certificate
                                                    example: SE
                                                  identifier:
                                                    nullable: true
                                                    type: string
                                                    description: The primary identifier, such as a Swedish Personal Number, as
                                                      specified in the signing
                                                      certificate
                                                    example: SE
                                                  signing_certificate:
                                                    nullable: true
                                                    type: string
                                                    description: The signing certificate for the signatory, returned by ZealID
                                                    example: >-
                                                      --BEGIN CERTIFICATE--

                                                      [BASE64 ENCODED
                                                      CERTIFICATE]

                                                      --END CERTIFICATE--
                                                  document_hash:
                                                    type: string
                                                    description: The SHA256 hash of the data to be signed (Base64 encoded)
                                                    example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                  status:
                                                    type: string
                                                    enum:
                                                      - draft
                                                      - awaiting_authentication
                                                      - awaiting_sign
                                                      - complete
                                                      - failed
                                                    description: The status for the ZealID signing process
                                                required:
                                                  - givenname
                                                  - surname
                                                  - country
                                                  - identifier
                                                  - signing_certificate
                                                  - document_hash
                                                  - status
                                                description: Summary of the ZealID signature data
                                            required:
                                              - method
                                              - data
                                  - type: object
                                    properties:
                                      method:
                                        type: string
                                        nullable: true
                                        format: "null"
                                      data:
                                        type: string
                                        nullable: true
                                        format: "null"
                                    required:
                                      - method
                                      - data
                                description: The signature data for the participant
                              identity_enforcement:
                                discriminator:
                                  propertyName: enabled
                                oneOf:
                                  - type: object
                                    properties:
                                      enabled:
                                        type: boolean
                                        enum:
                                          - true
                                        description: If true, identity enforcement is enabled for the participant
                                      status:
                                        type: string
                                        enum:
                                          - pending
                                          - passed
                                          - failed
                                        description: The status of the identity enforcement
                                      enforcement_method:
                                        type: string
                                        enum:
                                          - swe_pno_crosscheck
                                        description: The enforcement method for the identity. Depending on which method
                                          is used, different signature method
                                          are available
                                    required:
                                      - enabled
                                      - status
                                      - enforcement_method
                                  - type: object
                                    properties:
                                      enabled:
                                        type: boolean
                                        enum:
                                          - false
                                        description: If true, identity enforcement is enabled for the participant
                                      status:
                                        type: string
                                        nullable: true
                                        format: "null"
                                      enforcement_method:
                                        type: string
                                        nullable: true
                                        format: "null"
                                    required:
                                      - enabled
                                      - status
                                      - enforcement_method
                            required:
                              - role
                              - signed_at
                              - signature
                              - identity_enforcement
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: PUT /agreements/:agreement_id/participants/:participant_id Error
            response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Updates an existing participant. The agreement must be in draft
        status in order to update a participant. If the agreement is in open
        status, the exisiting participants are immutable. In the case of an open
        agreement, you can still add and delete participants.
      summary: Update a Participant
      tags:
        - Agreements
        - Participants
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: PUT /agreements/:agreement_id/participants/:participant_id parameter
          schema:
            type: string
            format: cuid
            example: ciaa8pbsstalpikklynexample
        - name: participant_id
          in: path
          required: true
          description: PUT /agreements/:agreement_id/participants/:participant_id parameter
          schema:
            type: string
            format: cuid
            example: cwxnc0a4ttwhcigujcjexample
      requestBody:
        description: PUT /agreements/:agreement_id/participants/:participant_id request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - allOf:
                                - type: object
                                  properties: {}
                                - type: object
                                  properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                          required: []
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    email:
                      type: string
                      description: The email of the participant. Will be used in all communication, if
                        email communication is enabled for the agreement.
                    name:
                      type: string
                      description: The name of the participant. If omitted, the email adress will be
                        used as name.
                    role:
                      type: string
                      enum:
                        - signer
                        - approver
                      description: The role of the participant within the signing process. If the
                        agreement is configured for qualified signatures, only
                        "signer" is supported. Default role is "signer".
                    identity_enforcement:
                      oneOf:
                        - type: object
                          properties:
                            personal_number:
                              type: string
                              description: The personal number of the participant. If provided, the signer
                                will have to use an advanced signing method
                                which supports swedish personal numbers to sign
                                the agreement and only be allowed to sign if the
                                personal number matches what is provided. Only
                                available for signers.
                          required:
                            - personal_number
                        - type: object
                          properties:
                            disable:
                              type: boolean
                              enum:
                                - true
                              description: Disables identity enforcement for the participant, if already
                                enabled
                          required:
                            - disable
                    order:
                      type: integer
                      format: int64
                      minimum: -9007199254740991
                      exclusiveMinimum: false
                      maximum: 9007199254740991
                      exclusiveMaximum: false
                      description: Only applicable if signing order is enabled for the agreement. It
                        specifies the order in the signing queue this
                        participant will have. Will be put last in line if not
                        specified. If multiple participants share the same queue
                        number, this participant will take precendent and the
                        rest will be moved forward accordingly.
                    locale:
                      type: string
                      enum:
                        - sv-SE
                        - en-US
                      default: sv-SE
                      description: Optional. The locale for the participant. Can be overridden by the
                        participant when signing, but the locale provided by you
                        will serve as the default in initial communication. If
                        not specified, the default locale for the agreement will
                        be used.
                  required: []
      security:
        - HTTP_1: []
    delete:
      operationId: DeleteAgreementsAgreementIdParticipantsParticipantId
      responses:
        "200":
          description: DELETE /agreements/:agreement_id/participants/:participant_id
            Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - deleted
                    description: Returns a single object of the participant resource which was
                      deleted.
                  resource_type:
                    type: string
                    enum:
                      - participant
                    description: Data contains the participant resource.
                  data:
                    allOf:
                      - type: object
                        properties:
                          id:
                            type: string
                            format: cuid
                            description: The unique identifier of the participant
                            example: c7uwzf2hygix6pmzsh5example
                          resource_type:
                            type: string
                            enum:
                              - participant
                          name:
                            nullable: true
                            type: string
                            description: The name of the participant. Required if no email is provided.
                            example: Jane Doe
                          email:
                            nullable: true
                            type: string
                            description: The email of the participant. Required if agreemnt is configured to
                              send emails.
                            example: jane.doe@example.com
                          status:
                            type: string
                            enum:
                              - draft
                              - pending
                              - initiated
                              - processing
                              - fulfilled
                              - rejected
                            description: The status of the participant
                          order:
                            nullable: true
                            type: number
                            format: double
                            minimum: 0
                            exclusiveMinimum: true
                            maximum: 1.7976931348623157e+308
                            exclusiveMaximum: false
                            description: The queue number of the participant (if sequential signing order is
                              enabled)
                            example: 1
                          signing_group:
                            oneOf:
                              - type: string
                                format: cuid
                                description: The unique identifier for the signing groups
                                example: cgbzlzelirbjrjq0xrxexample
                              - $ref: "#/components/schemas/118cb3b11b8a1f3b6b1e60a89f96a8be9da32a0f"
                              - type: string
                                nullable: true
                                format: "null"
                          agreement:
                            type: string
                            format: cuid
                            description: The unique identifier for the agreement this participant belongs to
                            example: cj2orx6w6iqpscuqsieexample
                          signing_room_url:
                            nullable: true
                            type: string
                            format: url
                            example: https://www.zigned.se/sign/cjecfacxrxzqd9def5zexample/cmakdfl6yfb9ls8h6jyexample
                            description: The URL to the signing room for the participant. Only available
                              after the agreement has been finalized for
                              signing.
                          locale:
                            nullable: true
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                            description: The locale for the participant. Can be overridden from the signing
                              room, but this value serves as the default if
                              nothing else is specified.
                          created_at:
                            type: string
                            description: UTC datetime ISO string
                            example: 2024-01-01T00:00:00.000Z
                          updated_at:
                            type: string
                            description: UTC datetime ISO string
                            example: 2024-01-01T00:00:00.000Z
                        required:
                          - id
                          - resource_type
                          - name
                          - email
                          - status
                          - order
                          - signing_group
                          - agreement
                          - signing_room_url
                          - created_at
                          - updated_at
                        description: The participant resource
                      - discriminator:
                          propertyName: role
                        oneOf:
                          - type: object
                            properties:
                              role:
                                type: string
                                enum:
                                  - approver
                                description: The role of the participant
                              decision_made_at:
                                nullable: true
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                            required:
                              - role
                              - decision_made_at
                          - type: object
                            properties:
                              role:
                                type: string
                                enum:
                                  - signer
                                description: The role of the participant
                              signed_at:
                                nullable: true
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                              signature:
                                nullable: true
                                oneOf:
                                  - allOf:
                                      - type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the signature data
                                            example: cqdax9rdsuqyvtgemlzexample
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - created_at
                                          - updated_at
                                      - discriminator:
                                          propertyName: method
                                        oneOf:
                                          - type: object
                                            properties:
                                              method:
                                                type: string
                                                enum:
                                                  - se_bid
                                                description: The method used for signing
                                              data:
                                                type: object
                                                properties:
                                                  name:
                                                    nullable: true
                                                    type: string
                                                    description: The full name of the signer returned by Mobile Swedish BankID
                                                    example: Jane Doe
                                                  user_message:
                                                    type: string
                                                    description: The message presented to the user in the Mobile BankID application
                                                      when signing
                                                    example: I have read and understood the contents of the document example.pdf and
                                                      I hereby approve
                                                      everything in it.
                                                  document_hash:
                                                    type: string
                                                    description: The SHA256 hash of the document to be signed (Base64 encoded)
                                                    example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                  status:
                                                    type: string
                                                    enum:
                                                      - complete
                                                      - error
                                                      - failed
                                                      - draft
                                                      - pending
                                                      - initializing
                                                      - cancelled
                                                    description: The status for the Swedish BankID signing process
                                                required:
                                                  - name
                                                  - user_message
                                                  - document_hash
                                                  - status
                                                description: Summary of the BankID signature data
                                            required:
                                              - method
                                              - data
                                          - type: object
                                            properties:
                                              method:
                                                type: string
                                                enum:
                                                  - verification_code
                                                description: The method used for signing
                                              data:
                                                type: object
                                                properties:
                                                  email:
                                                    nullable: true
                                                    type: string
                                                    description: The email used for the verification code
                                                    example: john.doe@example.com
                                                  name:
                                                    nullable: true
                                                    type: string
                                                    description: The name of the signer
                                                    example: John Doe
                                                  user_message:
                                                    type: string
                                                    description: The message presented to the user when signing
                                                    example: I have read and understood the contents of the document example.pdf and
                                                      I hereby approve
                                                      everything in it.
                                                  document_hash:
                                                    type: string
                                                    description: The SHA256 hash of the document to be signed (Base64 encoded)
                                                    example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                  status:
                                                    type: string
                                                    enum:
                                                      - confirmed
                                                      - draft
                                                      - pending
                                                      - confirmation_failed
                                                      - unable_to_send
                                                      - expired
                                                      - cancelled
                                                    description: The status of the verification code signing process
                                                required:
                                                  - email
                                                  - name
                                                  - user_message
                                                  - document_hash
                                                  - status
                                                description: Summary of the verification code signature data
                                            required:
                                              - method
                                              - data
                                          - type: object
                                            properties:
                                              method:
                                                type: string
                                                enum:
                                                  - truid
                                                description: The method used for signing
                                              data:
                                                type: object
                                                properties:
                                                  given_name:
                                                    nullable: true
                                                    type: string
                                                    description: The given name of the signer returned by Truid
                                                    example: Jane
                                                  family_name:
                                                    nullable: true
                                                    type: string
                                                    description: The family name of the signer returned by Truid
                                                    example: Doe
                                                  legal_name:
                                                    nullable: true
                                                    type: string
                                                    description: The legal name of the signer returned by Truid
                                                    example: Jane Doe
                                                  user_message:
                                                    type: string
                                                    description: The message presented to the user in the Truid application when
                                                      signing
                                                    example: I have read and wish to sign the document.
                                                  document_hash:
                                                    type: string
                                                    description: The SHA256 hash of the document to be signed (Base64 encoded)
                                                    example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                  status:
                                                    type: string
                                                    enum:
                                                      - draft
                                                      - pending
                                                      - fulfilled
                                                      - failed
                                                    description: The status for the Truid signing process
                                                required:
                                                  - given_name
                                                  - family_name
                                                  - legal_name
                                                  - user_message
                                                  - document_hash
                                                  - status
                                                description: Summary of the Truid signature data
                                            required:
                                              - method
                                              - data
                                          - type: object
                                            properties:
                                              method:
                                                type: string
                                                enum:
                                                  - zealid
                                                description: The method used for signing
                                              data:
                                                type: object
                                                properties:
                                                  givenname:
                                                    nullable: true
                                                    type: string
                                                    description: The given name of the signer as specified in the signing
                                                      certificate
                                                    example: Jane
                                                  surname:
                                                    nullable: true
                                                    type: string
                                                    description: The surname of the signer as specified in the signing certificate
                                                    example: Doe
                                                  country:
                                                    nullable: true
                                                    type: string
                                                    description: The country of the signer as specified in the signing certificate
                                                    example: SE
                                                  identifier:
                                                    nullable: true
                                                    type: string
                                                    description: The primary identifier, such as a Swedish Personal Number, as
                                                      specified in the signing
                                                      certificate
                                                    example: SE
                                                  signing_certificate:
                                                    nullable: true
                                                    type: string
                                                    description: The signing certificate for the signatory, returned by ZealID
                                                    example: >-
                                                      --BEGIN CERTIFICATE--

                                                      [BASE64 ENCODED
                                                      CERTIFICATE]

                                                      --END CERTIFICATE--
                                                  document_hash:
                                                    type: string
                                                    description: The SHA256 hash of the data to be signed (Base64 encoded)
                                                    example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                  status:
                                                    type: string
                                                    enum:
                                                      - draft
                                                      - awaiting_authentication
                                                      - awaiting_sign
                                                      - complete
                                                      - failed
                                                    description: The status for the ZealID signing process
                                                required:
                                                  - givenname
                                                  - surname
                                                  - country
                                                  - identifier
                                                  - signing_certificate
                                                  - document_hash
                                                  - status
                                                description: Summary of the ZealID signature data
                                            required:
                                              - method
                                              - data
                                  - type: object
                                    properties:
                                      method:
                                        type: string
                                        nullable: true
                                        format: "null"
                                      data:
                                        type: string
                                        nullable: true
                                        format: "null"
                                    required:
                                      - method
                                      - data
                                description: The signature data for the participant
                              identity_enforcement:
                                discriminator:
                                  propertyName: enabled
                                oneOf:
                                  - type: object
                                    properties:
                                      enabled:
                                        type: boolean
                                        enum:
                                          - true
                                        description: If true, identity enforcement is enabled for the participant
                                      status:
                                        type: string
                                        enum:
                                          - pending
                                          - passed
                                          - failed
                                        description: The status of the identity enforcement
                                      enforcement_method:
                                        type: string
                                        enum:
                                          - swe_pno_crosscheck
                                        description: The enforcement method for the identity. Depending on which method
                                          is used, different signature method
                                          are available
                                    required:
                                      - enabled
                                      - status
                                      - enforcement_method
                                  - type: object
                                    properties:
                                      enabled:
                                        type: boolean
                                        enum:
                                          - false
                                        description: If true, identity enforcement is enabled for the participant
                                      status:
                                        type: string
                                        nullable: true
                                        format: "null"
                                      enforcement_method:
                                        type: string
                                        nullable: true
                                        format: "null"
                                    required:
                                      - enabled
                                      - status
                                      - enforcement_method
                            required:
                              - role
                              - signed_at
                              - signature
                              - identity_enforcement
                    description: The resource data that was deleted.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: DELETE /agreements/:agreement_id/participants/:participant_id Error
            response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Deletes an existing participant. The participant must be in `draft`
        status
      summary: Delete a Participant
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: DELETE /agreements/:agreement_id/participants/:participant_id
            parameter
          schema:
            type: string
            format: cuid
            example: c5b3k3s6hkbgc0ph3i3example
        - name: participant_id
          in: path
          required: true
          description: DELETE /agreements/:agreement_id/participants/:participant_id
            parameter
          schema:
            type: string
            format: cuid
            example: ckyzupy4nko6xemopedexample
      security:
        - HTTP_1: []
    get:
      operationId: GetAgreementsAgreementIdParticipantsParticipantId
      responses:
        "200":
          description: GET /agreements/:agreement_id/participants/:participant_id
            Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the participant resource.
                  resource_type:
                    type: string
                    enum:
                      - participant
                    description: Data contains the participant resource.
                  data:
                    allOf:
                      - type: object
                        properties:
                          id:
                            type: string
                            format: cuid
                            description: The unique identifier of the participant
                            example: c7uwzf2hygix6pmzsh5example
                          resource_type:
                            type: string
                            enum:
                              - participant
                          name:
                            nullable: true
                            type: string
                            description: The name of the participant. Required if no email is provided.
                            example: Jane Doe
                          email:
                            nullable: true
                            type: string
                            description: The email of the participant. Required if agreemnt is configured to
                              send emails.
                            example: jane.doe@example.com
                          status:
                            type: string
                            enum:
                              - draft
                              - pending
                              - initiated
                              - processing
                              - fulfilled
                              - rejected
                            description: The status of the participant
                          order:
                            nullable: true
                            type: number
                            format: double
                            minimum: 0
                            exclusiveMinimum: true
                            maximum: 1.7976931348623157e+308
                            exclusiveMaximum: false
                            description: The queue number of the participant (if sequential signing order is
                              enabled)
                            example: 1
                          signing_group:
                            oneOf:
                              - type: string
                                format: cuid
                                description: The unique identifier for the signing groups
                                example: cgbzlzelirbjrjq0xrxexample
                              - $ref: "#/components/schemas/118cb3b11b8a1f3b6b1e60a89f96a8be9da32a0f"
                              - type: string
                                nullable: true
                                format: "null"
                          agreement:
                            type: string
                            format: cuid
                            description: The unique identifier for the agreement this participant belongs to
                            example: cj2orx6w6iqpscuqsieexample
                          signing_room_url:
                            nullable: true
                            type: string
                            format: url
                            example: https://www.zigned.se/sign/cjecfacxrxzqd9def5zexample/cmakdfl6yfb9ls8h6jyexample
                            description: The URL to the signing room for the participant. Only available
                              after the agreement has been finalized for
                              signing.
                          locale:
                            nullable: true
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                            description: The locale for the participant. Can be overridden from the signing
                              room, but this value serves as the default if
                              nothing else is specified.
                          created_at:
                            type: string
                            description: UTC datetime ISO string
                            example: 2024-01-01T00:00:00.000Z
                          updated_at:
                            type: string
                            description: UTC datetime ISO string
                            example: 2024-01-01T00:00:00.000Z
                        required:
                          - id
                          - resource_type
                          - name
                          - email
                          - status
                          - order
                          - signing_group
                          - agreement
                          - signing_room_url
                          - created_at
                          - updated_at
                        description: The participant resource
                      - discriminator:
                          propertyName: role
                        oneOf:
                          - type: object
                            properties:
                              role:
                                type: string
                                enum:
                                  - approver
                                description: The role of the participant
                              decision_made_at:
                                nullable: true
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                            required:
                              - role
                              - decision_made_at
                          - type: object
                            properties:
                              role:
                                type: string
                                enum:
                                  - signer
                                description: The role of the participant
                              signed_at:
                                nullable: true
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                              signature:
                                nullable: true
                                oneOf:
                                  - allOf:
                                      - type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the signature data
                                            example: cqdax9rdsuqyvtgemlzexample
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - created_at
                                          - updated_at
                                      - discriminator:
                                          propertyName: method
                                        oneOf:
                                          - type: object
                                            properties:
                                              method:
                                                type: string
                                                enum:
                                                  - se_bid
                                                description: The method used for signing
                                              data:
                                                type: object
                                                properties:
                                                  name:
                                                    nullable: true
                                                    type: string
                                                    description: The full name of the signer returned by Mobile Swedish BankID
                                                    example: Jane Doe
                                                  user_message:
                                                    type: string
                                                    description: The message presented to the user in the Mobile BankID application
                                                      when signing
                                                    example: I have read and understood the contents of the document example.pdf and
                                                      I hereby approve
                                                      everything in it.
                                                  document_hash:
                                                    type: string
                                                    description: The SHA256 hash of the document to be signed (Base64 encoded)
                                                    example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                  status:
                                                    type: string
                                                    enum:
                                                      - complete
                                                      - error
                                                      - failed
                                                      - draft
                                                      - pending
                                                      - initializing
                                                      - cancelled
                                                    description: The status for the Swedish BankID signing process
                                                required:
                                                  - name
                                                  - user_message
                                                  - document_hash
                                                  - status
                                                description: Summary of the BankID signature data
                                            required:
                                              - method
                                              - data
                                          - type: object
                                            properties:
                                              method:
                                                type: string
                                                enum:
                                                  - verification_code
                                                description: The method used for signing
                                              data:
                                                type: object
                                                properties:
                                                  email:
                                                    nullable: true
                                                    type: string
                                                    description: The email used for the verification code
                                                    example: john.doe@example.com
                                                  name:
                                                    nullable: true
                                                    type: string
                                                    description: The name of the signer
                                                    example: John Doe
                                                  user_message:
                                                    type: string
                                                    description: The message presented to the user when signing
                                                    example: I have read and understood the contents of the document example.pdf and
                                                      I hereby approve
                                                      everything in it.
                                                  document_hash:
                                                    type: string
                                                    description: The SHA256 hash of the document to be signed (Base64 encoded)
                                                    example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                  status:
                                                    type: string
                                                    enum:
                                                      - confirmed
                                                      - draft
                                                      - pending
                                                      - confirmation_failed
                                                      - unable_to_send
                                                      - expired
                                                      - cancelled
                                                    description: The status of the verification code signing process
                                                required:
                                                  - email
                                                  - name
                                                  - user_message
                                                  - document_hash
                                                  - status
                                                description: Summary of the verification code signature data
                                            required:
                                              - method
                                              - data
                                          - type: object
                                            properties:
                                              method:
                                                type: string
                                                enum:
                                                  - truid
                                                description: The method used for signing
                                              data:
                                                type: object
                                                properties:
                                                  given_name:
                                                    nullable: true
                                                    type: string
                                                    description: The given name of the signer returned by Truid
                                                    example: Jane
                                                  family_name:
                                                    nullable: true
                                                    type: string
                                                    description: The family name of the signer returned by Truid
                                                    example: Doe
                                                  legal_name:
                                                    nullable: true
                                                    type: string
                                                    description: The legal name of the signer returned by Truid
                                                    example: Jane Doe
                                                  user_message:
                                                    type: string
                                                    description: The message presented to the user in the Truid application when
                                                      signing
                                                    example: I have read and wish to sign the document.
                                                  document_hash:
                                                    type: string
                                                    description: The SHA256 hash of the document to be signed (Base64 encoded)
                                                    example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                  status:
                                                    type: string
                                                    enum:
                                                      - draft
                                                      - pending
                                                      - fulfilled
                                                      - failed
                                                    description: The status for the Truid signing process
                                                required:
                                                  - given_name
                                                  - family_name
                                                  - legal_name
                                                  - user_message
                                                  - document_hash
                                                  - status
                                                description: Summary of the Truid signature data
                                            required:
                                              - method
                                              - data
                                          - type: object
                                            properties:
                                              method:
                                                type: string
                                                enum:
                                                  - zealid
                                                description: The method used for signing
                                              data:
                                                type: object
                                                properties:
                                                  givenname:
                                                    nullable: true
                                                    type: string
                                                    description: The given name of the signer as specified in the signing
                                                      certificate
                                                    example: Jane
                                                  surname:
                                                    nullable: true
                                                    type: string
                                                    description: The surname of the signer as specified in the signing certificate
                                                    example: Doe
                                                  country:
                                                    nullable: true
                                                    type: string
                                                    description: The country of the signer as specified in the signing certificate
                                                    example: SE
                                                  identifier:
                                                    nullable: true
                                                    type: string
                                                    description: The primary identifier, such as a Swedish Personal Number, as
                                                      specified in the signing
                                                      certificate
                                                    example: SE
                                                  signing_certificate:
                                                    nullable: true
                                                    type: string
                                                    description: The signing certificate for the signatory, returned by ZealID
                                                    example: >-
                                                      --BEGIN CERTIFICATE--

                                                      [BASE64 ENCODED
                                                      CERTIFICATE]

                                                      --END CERTIFICATE--
                                                  document_hash:
                                                    type: string
                                                    description: The SHA256 hash of the data to be signed (Base64 encoded)
                                                    example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                  status:
                                                    type: string
                                                    enum:
                                                      - draft
                                                      - awaiting_authentication
                                                      - awaiting_sign
                                                      - complete
                                                      - failed
                                                    description: The status for the ZealID signing process
                                                required:
                                                  - givenname
                                                  - surname
                                                  - country
                                                  - identifier
                                                  - signing_certificate
                                                  - document_hash
                                                  - status
                                                description: Summary of the ZealID signature data
                                            required:
                                              - method
                                              - data
                                  - type: object
                                    properties:
                                      method:
                                        type: string
                                        nullable: true
                                        format: "null"
                                      data:
                                        type: string
                                        nullable: true
                                        format: "null"
                                    required:
                                      - method
                                      - data
                                description: The signature data for the participant
                              identity_enforcement:
                                discriminator:
                                  propertyName: enabled
                                oneOf:
                                  - type: object
                                    properties:
                                      enabled:
                                        type: boolean
                                        enum:
                                          - true
                                        description: If true, identity enforcement is enabled for the participant
                                      status:
                                        type: string
                                        enum:
                                          - pending
                                          - passed
                                          - failed
                                        description: The status of the identity enforcement
                                      enforcement_method:
                                        type: string
                                        enum:
                                          - swe_pno_crosscheck
                                        description: The enforcement method for the identity. Depending on which method
                                          is used, different signature method
                                          are available
                                    required:
                                      - enabled
                                      - status
                                      - enforcement_method
                                  - type: object
                                    properties:
                                      enabled:
                                        type: boolean
                                        enum:
                                          - false
                                        description: If true, identity enforcement is enabled for the participant
                                      status:
                                        type: string
                                        nullable: true
                                        format: "null"
                                      enforcement_method:
                                        type: string
                                        nullable: true
                                        format: "null"
                                    required:
                                      - enabled
                                      - status
                                      - enforcement_method
                            required:
                              - role
                              - signed_at
                              - signature
                              - identity_enforcement
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: GET /agreements/:agreement_id/participants/:participant_id Error
            response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Retrieves a participant of the Agreement.
      summary: Retrieve a Participant
      tags:
        - Agreements
        - Participants
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: GET /agreements/:agreement_id/participants/:participant_id parameter
          schema:
            type: string
            format: cuid
            example: cja2gpe3dwn7tgegeejexample
        - name: participant_id
          in: path
          required: true
          description: GET /agreements/:agreement_id/participants/:participant_id parameter
          schema:
            type: string
            format: cuid
            example: cojgygq5n6lu2xdzhpvexample
      security:
        - HTTP_1: []
  /agreements/{agreement_id}/participants/{participant_id}/sign_events:
    get:
      operationId: GetAgreementsAgreementIdParticipantsParticipantIdSignEvents
      responses:
        "200":
          description: GET
            /agreements/:agreement_id/participants/:participant_id/sign_events
            Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - list
                    description: A non-paginated list of the sign event resource.
                  resource_type:
                    type: string
                    enum:
                      - sign_event
                    description: Data contains the sign event resource.
                  data:
                    $ref: "#/components/schemas/86d5051e0c6984da525697fc9654ac089e947844"
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: GET
            /agreements/:agreement_id/participants/:participant_id/sign_events
            Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Lists all sign events for the participant. The events are returned
        in ascending order by creation date. Events are read only.
      summary: List Sign Events
      tags:
        - Agreements
        - Participants
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: GET
            /agreements/:agreement_id/participants/:participant_id/sign_events
            parameter
          schema:
            type: string
            format: cuid
            example: cnxscypbrbsufjvje3nexample
        - name: participant_id
          in: path
          required: true
          description: GET
            /agreements/:agreement_id/participants/:participant_id/sign_events
            parameter
          schema:
            type: string
            format: cuid
            example: csofuxek9ii5txigjnxexample
      security:
        - HTTP_1: []
  /agreements/{agreement_id}/participants/{participant_id}/forward:
    post:
      operationId: PostAgreementsAgreementIdParticipantsParticipantIdForward
      responses:
        "200":
          description: POST /agreements/:agreement_id/participants/:participant_id/forward
            Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                  resource_type:
                    type: string
                    enum:
                      - forward
                  result_type:
                    type: string
                    enum:
                      - single
                  data:
                    type: object
                    properties:
                      status:
                        type: string
                      previous_email:
                        type: string
                      forwarded_to_email:
                        type: string
                      participant:
                        type: object
                        properties:
                          version:
                            type: string
                            enum:
                              - "1.0"
                            description: The version of the response schema
                          result_type:
                            type: string
                            enum:
                              - single
                            description: A single object of the participant resource.
                          resource_type:
                            type: string
                            enum:
                              - participant
                            description: Data contains the participant resource.
                          data:
                            allOf:
                              - type: object
                                properties:
                                  id:
                                    type: string
                                    format: cuid
                                    description: The unique identifier of the participant
                                    example: c7uwzf2hygix6pmzsh5example
                                  resource_type:
                                    type: string
                                    enum:
                                      - participant
                                  name:
                                    nullable: true
                                    type: string
                                    description: The name of the participant. Required if no email is provided.
                                    example: Jane Doe
                                  email:
                                    nullable: true
                                    type: string
                                    description: The email of the participant. Required if agreemnt is configured to
                                      send emails.
                                    example: jane.doe@example.com
                                  status:
                                    type: string
                                    enum:
                                      - draft
                                      - pending
                                      - initiated
                                      - processing
                                      - fulfilled
                                      - rejected
                                    description: The status of the participant
                                  order:
                                    nullable: true
                                    type: number
                                    format: double
                                    minimum: 0
                                    exclusiveMinimum: true
                                    maximum: 1.7976931348623157e+308
                                    exclusiveMaximum: false
                                    description: The queue number of the participant (if sequential signing order is
                                      enabled)
                                    example: 1
                                  signing_group:
                                    oneOf:
                                      - type: string
                                        format: cuid
                                        description: The unique identifier for the signing groups
                                        example: cgbzlzelirbjrjq0xrxexample
                                      - $ref: "#/components/schemas/118cb3b11b8a1f3b6b1e60a89f96a8be9da32a0f"
                                      - type: string
                                        nullable: true
                                        format: "null"
                                  agreement:
                                    type: string
                                    format: cuid
                                    description: The unique identifier for the agreement this participant belongs to
                                    example: cj2orx6w6iqpscuqsieexample
                                  signing_room_url:
                                    nullable: true
                                    type: string
                                    format: url
                                    example: https://www.zigned.se/sign/cjecfacxrxzqd9def5zexample/cmakdfl6yfb9ls8h6jyexample
                                    description: The URL to the signing room for the participant. Only available
                                      after the agreement has been finalized for
                                      signing.
                                  locale:
                                    nullable: true
                                    type: string
                                    enum:
                                      - sv-SE
                                      - en-US
                                    description: The locale for the participant. Can be overridden from the signing
                                      room, but this value serves as the default
                                      if nothing else is specified.
                                  created_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                  updated_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                required:
                                  - id
                                  - resource_type
                                  - name
                                  - email
                                  - status
                                  - order
                                  - signing_group
                                  - agreement
                                  - signing_room_url
                                  - created_at
                                  - updated_at
                                description: The participant resource
                              - discriminator:
                                  propertyName: role
                                oneOf:
                                  - type: object
                                    properties:
                                      role:
                                        type: string
                                        enum:
                                          - approver
                                        description: The role of the participant
                                      decision_made_at:
                                        nullable: true
                                        type: string
                                        description: UTC datetime ISO string
                                        example: 2024-01-01T00:00:00.000Z
                                    required:
                                      - role
                                      - decision_made_at
                                  - type: object
                                    properties:
                                      role:
                                        type: string
                                        enum:
                                          - signer
                                        description: The role of the participant
                                      signed_at:
                                        nullable: true
                                        type: string
                                        description: UTC datetime ISO string
                                        example: 2024-01-01T00:00:00.000Z
                                      signature:
                                        nullable: true
                                        oneOf:
                                          - allOf:
                                              - type: object
                                                properties:
                                                  id:
                                                    type: string
                                                    format: cuid
                                                    description: The unique identifier of the signature data
                                                    example: cqdax9rdsuqyvtgemlzexample
                                                  created_at:
                                                    type: string
                                                    description: UTC datetime ISO string
                                                    example: 2024-01-01T00:00:00.000Z
                                                  updated_at:
                                                    type: string
                                                    description: UTC datetime ISO string
                                                    example: 2024-01-01T00:00:00.000Z
                                                required:
                                                  - id
                                                  - created_at
                                                  - updated_at
                                              - discriminator:
                                                  propertyName: method
                                                oneOf:
                                                  - type: object
                                                    properties:
                                                      method:
                                                        type: string
                                                        enum:
                                                          - se_bid
                                                        description: The method used for signing
                                                      data:
                                                        type: object
                                                        properties:
                                                          name:
                                                            nullable: true
                                                            type: string
                                                            description: The full name of the signer returned by Mobile Swedish BankID
                                                            example: Jane Doe
                                                          user_message:
                                                            type: string
                                                            description: The message presented to the user in the Mobile BankID application
                                                              when signing
                                                            example: I have read and understood the contents of the document example.pdf and
                                                              I hereby approve
                                                              everything in it.
                                                          document_hash:
                                                            type: string
                                                            description: The SHA256 hash of the document to be signed (Base64 encoded)
                                                            example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                          status:
                                                            type: string
                                                            enum:
                                                              - complete
                                                              - error
                                                              - failed
                                                              - draft
                                                              - pending
                                                              - initializing
                                                              - cancelled
                                                            description: The status for the Swedish BankID signing process
                                                        required:
                                                          - name
                                                          - user_message
                                                          - document_hash
                                                          - status
                                                        description: Summary of the BankID signature data
                                                    required:
                                                      - method
                                                      - data
                                                  - type: object
                                                    properties:
                                                      method:
                                                        type: string
                                                        enum:
                                                          - verification_code
                                                        description: The method used for signing
                                                      data:
                                                        type: object
                                                        properties:
                                                          email:
                                                            nullable: true
                                                            type: string
                                                            description: The email used for the verification code
                                                            example: john.doe@example.com
                                                          name:
                                                            nullable: true
                                                            type: string
                                                            description: The name of the signer
                                                            example: John Doe
                                                          user_message:
                                                            type: string
                                                            description: The message presented to the user when signing
                                                            example: I have read and understood the contents of the document example.pdf and
                                                              I hereby approve
                                                              everything in it.
                                                          document_hash:
                                                            type: string
                                                            description: The SHA256 hash of the document to be signed (Base64 encoded)
                                                            example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                          status:
                                                            type: string
                                                            enum:
                                                              - confirmed
                                                              - draft
                                                              - pending
                                                              - confirmation_failed
                                                              - unable_to_send
                                                              - expired
                                                              - cancelled
                                                            description: The status of the verification code signing process
                                                        required:
                                                          - email
                                                          - name
                                                          - user_message
                                                          - document_hash
                                                          - status
                                                        description: Summary of the verification code signature data
                                                    required:
                                                      - method
                                                      - data
                                                  - type: object
                                                    properties:
                                                      method:
                                                        type: string
                                                        enum:
                                                          - truid
                                                        description: The method used for signing
                                                      data:
                                                        type: object
                                                        properties:
                                                          given_name:
                                                            nullable: true
                                                            type: string
                                                            description: The given name of the signer returned by Truid
                                                            example: Jane
                                                          family_name:
                                                            nullable: true
                                                            type: string
                                                            description: The family name of the signer returned by Truid
                                                            example: Doe
                                                          legal_name:
                                                            nullable: true
                                                            type: string
                                                            description: The legal name of the signer returned by Truid
                                                            example: Jane Doe
                                                          user_message:
                                                            type: string
                                                            description: The message presented to the user in the Truid application when
                                                              signing
                                                            example: I have read and wish to sign the document.
                                                          document_hash:
                                                            type: string
                                                            description: The SHA256 hash of the document to be signed (Base64 encoded)
                                                            example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                          status:
                                                            type: string
                                                            enum:
                                                              - draft
                                                              - pending
                                                              - fulfilled
                                                              - failed
                                                            description: The status for the Truid signing process
                                                        required:
                                                          - given_name
                                                          - family_name
                                                          - legal_name
                                                          - user_message
                                                          - document_hash
                                                          - status
                                                        description: Summary of the Truid signature data
                                                    required:
                                                      - method
                                                      - data
                                                  - type: object
                                                    properties:
                                                      method:
                                                        type: string
                                                        enum:
                                                          - zealid
                                                        description: The method used for signing
                                                      data:
                                                        type: object
                                                        properties:
                                                          givenname:
                                                            nullable: true
                                                            type: string
                                                            description: The given name of the signer as specified in the signing
                                                              certificate
                                                            example: Jane
                                                          surname:
                                                            nullable: true
                                                            type: string
                                                            description: The surname of the signer as specified in the signing certificate
                                                            example: Doe
                                                          country:
                                                            nullable: true
                                                            type: string
                                                            description: The country of the signer as specified in the signing certificate
                                                            example: SE
                                                          identifier:
                                                            nullable: true
                                                            type: string
                                                            description: The primary identifier, such as a Swedish Personal Number, as
                                                              specified in the
                                                              signing certificate
                                                            example: SE
                                                          signing_certificate:
                                                            nullable: true
                                                            type: string
                                                            description: The signing certificate for the signatory, returned by ZealID
                                                            example: >-
                                                              
                                                              --BEGIN
                                                              CERTIFICATE--

                                                              [BASE64 ENCODED
                                                              CERTIFICATE]

                                                              --END CERTIFICATE--
                                                          document_hash:
                                                            type: string
                                                            description: The SHA256 hash of the data to be signed (Base64 encoded)
                                                            example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                          status:
                                                            type: string
                                                            enum:
                                                              - draft
                                                              - awaiting_authentication
                                                              - awaiting_sign
                                                              - complete
                                                              - failed
                                                            description: The status for the ZealID signing process
                                                        required:
                                                          - givenname
                                                          - surname
                                                          - country
                                                          - identifier
                                                          - signing_certificate
                                                          - document_hash
                                                          - status
                                                        description: Summary of the ZealID signature data
                                                    required:
                                                      - method
                                                      - data
                                          - type: object
                                            properties:
                                              method:
                                                type: string
                                                nullable: true
                                                format: "null"
                                              data:
                                                type: string
                                                nullable: true
                                                format: "null"
                                            required:
                                              - method
                                              - data
                                        description: The signature data for the participant
                                      identity_enforcement:
                                        discriminator:
                                          propertyName: enabled
                                        oneOf:
                                          - type: object
                                            properties:
                                              enabled:
                                                type: boolean
                                                enum:
                                                  - true
                                                description: If true, identity enforcement is enabled for the participant
                                              status:
                                                type: string
                                                enum:
                                                  - pending
                                                  - passed
                                                  - failed
                                                description: The status of the identity enforcement
                                              enforcement_method:
                                                type: string
                                                enum:
                                                  - swe_pno_crosscheck
                                                description: The enforcement method for the identity. Depending on which method
                                                  is used, different signature
                                                  method are available
                                            required:
                                              - enabled
                                              - status
                                              - enforcement_method
                                          - type: object
                                            properties:
                                              enabled:
                                                type: boolean
                                                enum:
                                                  - false
                                                description: If true, identity enforcement is enabled for the participant
                                              status:
                                                type: string
                                                nullable: true
                                                format: "null"
                                              enforcement_method:
                                                type: string
                                                nullable: true
                                                format: "null"
                                            required:
                                              - enabled
                                              - status
                                              - enforcement_method
                                    required:
                                      - role
                                      - signed_at
                                      - signature
                                      - identity_enforcement
                            description: The resource data.
                        required:
                          - version
                          - result_type
                          - resource_type
                          - data
                    required:
                      - status
                      - previous_email
                      - forwarded_to_email
                      - participant
                required:
                  - version
                  - resource_type
                  - result_type
                  - data
        "400":
          description: POST /agreements/:agreement_id/participants/:participant_id/forward
            Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Forwards the invitation to sign to another email address
      summary: Forward a Participant
      tags:
        - Agreements
        - Forward
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: POST /agreements/:agreement_id/participants/:participant_id/forward
            parameter
          schema:
            type: string
            format: cuid
            example: c1rffoaemznflrzs57cexample
        - name: participant_id
          in: path
          required: true
          description: POST /agreements/:agreement_id/participants/:participant_id/forward
            parameter
          schema:
            type: string
            format: cuid
            example: cba9pr1xcglkm55sio8example
      requestBody:
        description: POST /agreements/:agreement_id/participants/:participant_id/forward
          request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - type: object
                              properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                    - type: object
                      properties: {}
                      required: []
                - type: object
                  properties:
                    forward_to_email:
                      type: string
                      example: john.doe@example.com
                  required:
                    - forward_to_email
      security:
        - HTTP_1: []
  /agreements/{agreement_id}/observers:
    post:
      operationId: PostAgreementsAgreementIdObservers
      responses:
        "200":
          description: POST /agreements/:agreement_id/observers Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the observer resource.
                  resource_type:
                    type: string
                    enum:
                      - observer
                    description: Data contains the observer resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the observer
                        example: cmxm8kdqkf9bxoalwinexample
                      resource_type:
                        type: string
                        enum:
                          - observer
                      name:
                        nullable: true
                        type: string
                        description: The name of the observer. Required if no email is provided.
                        example: Jane Doe
                      email:
                        nullable: true
                        type: string
                        description: The email of the observer. Required if agreement is configured to
                          send emails or if the observer_scope is 'cc'.
                        example: jane.doe@example.com
                      locale:
                        nullable: true
                        type: string
                        enum:
                          - sv-SE
                          - en-US
                        description: The locale for the observer. Can be overridden from the signing
                          room (if the observer_scope is 'viewer'), but this
                          value serves as the default if nothing else is
                          specified.
                      observer_scope:
                        type: string
                        enum:
                          - cc
                          - viewer
                        description: The scope of the observer. If specified as viewer, they will gain
                          access to the signing room to follow the process.
                          Otherwise, they will only receive the final, signed
                          document.
                      agreement:
                        type: string
                        format: cuid
                        description: The unique identifier for the agreement this observer belongs to
                        example: cp9tppmeltnhqeckzz3example
                      signing_room_url:
                        nullable: true
                        type: string
                        format: url
                        example: https://www.zigned.se/sign/cjecfacxrxzqd9def5zexample/cmakdfl6yfb9ls8h6jyexample
                        description: The URL to the signing room for the observer. Only available after
                          the agreement is not in draft.
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - name
                      - email
                      - observer_scope
                      - agreement
                      - signing_room_url
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: POST /agreements/:agreement_id/observers Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Creates a new observer. Use the observer ID in subsequent requests.
      summary: Create an Observer
      tags:
        - Agreements
        - Observers
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: POST /agreements/:agreement_id/observers parameter
          schema:
            type: string
            format: cuid
            example: c3uqiyo4adzedzbih64example
      requestBody:
        description: POST /agreements/:agreement_id/observers request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - allOf:
                                - type: object
                                  properties: {}
                                - type: object
                                  properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                          required: []
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    email:
                      type: string
                      format: email
                      description: The email of the observer. Will be used in all communication, if
                        email communication is enabled for the agreement.
                      example: example@example.com
                    name:
                      type: string
                      description: The name of the observer
                    observer_scope:
                      type: string
                      enum:
                        - viewer
                        - cc
                      default: viewer
                      description: Either "viewer" or "cc". If the observer is a viewer, they will
                        gain access to the signing room. Otherwise they will
                        only receive a copy of the signed document.
                      example: cc
                    locale:
                      type: string
                      enum:
                        - sv-SE
                        - en-US
                      default: sv-SE
                      description: Optional. The locale for the observer. Can be overridden by the
                        observer in the signing room (if observer_Scope is
                        'viewer'), but the locale provided by you will serve as
                        the default in initial communication. If not specified,
                        the default locale for the agreement will be used.
                  required: []
      security:
        - HTTP_1: []
    get:
      operationId: GetAgreementsAgreementIdObservers
      responses:
        "200":
          description: GET /agreements/:agreement_id/observers Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - list
                    description: A non-paginated list of the observer resource.
                  resource_type:
                    type: string
                    enum:
                      - observer
                    description: Data contains the observer resource.
                  data:
                    $ref: "#/components/schemas/c893c5c1d97a5bcbd8972ce188f48f8f75c6a171"
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: GET /agreements/:agreement_id/observers Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Lists all observers for the agreement. The observers are returned
        in the order they were created.
      summary: List Observers
      tags:
        - Agreements
        - Observers
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: GET /agreements/:agreement_id/observers parameter
          schema:
            type: string
            format: cuid
            example: c1l7boryfajphiavj0xexample
      security:
        - HTTP_1: []
  /agreements/{agreement_id}/observers/batch:
    post:
      operationId: PostAgreementsAgreementIdObserversBatch
      responses:
        "200":
          description: POST /agreements/:agreement_id/observers/batch Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - list
                    description: A non-paginated list of the observer resource.
                  resource_type:
                    type: string
                    enum:
                      - observer
                    description: Data contains the observer resource.
                  data:
                    $ref: "#/components/schemas/c893c5c1d97a5bcbd8972ce188f48f8f75c6a171"
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: POST /agreements/:agreement_id/observers/batch Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Batch creates new observers. Use the observer IDs in subsequent requests.
      summary: Batch create observers
      tags:
        - Agreements
        - Observers
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: POST /agreements/:agreement_id/observers/batch parameter
          schema:
            type: string
            format: cuid
            example: ceblllzlpkd7drauvfjexample
      requestBody:
        description: POST /agreements/:agreement_id/observers/batch request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - allOf:
                                - type: object
                                  properties: {}
                                - type: object
                                  properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                          required: []
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    observers:
                      type: array
                      items:
                        type: object
                        properties:
                          email:
                            type: string
                            format: email
                            description: The email of the observer. Will be used in all communication, if
                              email communication is enabled for the agreement.
                            example: example@example.com
                          name:
                            type: string
                            description: The name of the observer
                          observer_scope:
                            type: string
                            enum:
                              - viewer
                              - cc
                            default: viewer
                            description: Either "viewer" or "cc". If the observer is a viewer, they will
                              gain access to the signing room. Otherwise they
                              will only receive a copy of the signed document.
                            example: cc
                          locale:
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                            default: sv-SE
                            description: Optional. The locale for the observer. Can be overridden by the
                              observer in the signing room (if observer_Scope is
                              'viewer'), but the locale provided by you will
                              serve as the default in initial communication. If
                              not specified, the default locale for the
                              agreement will be used.
                  required:
                    - observers
      security:
        - HTTP_1: []
  /agreements/{agreement_id}/observers/{observer_id}:
    put:
      operationId: PutAgreementsAgreementIdObserversObserverId
      responses:
        "200":
          description: PUT /agreements/:agreement_id/observers/:observer_id Successful
            response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the observer resource.
                  resource_type:
                    type: string
                    enum:
                      - observer
                    description: Data contains the observer resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the observer
                        example: cmxm8kdqkf9bxoalwinexample
                      resource_type:
                        type: string
                        enum:
                          - observer
                      name:
                        nullable: true
                        type: string
                        description: The name of the observer. Required if no email is provided.
                        example: Jane Doe
                      email:
                        nullable: true
                        type: string
                        description: The email of the observer. Required if agreement is configured to
                          send emails or if the observer_scope is 'cc'.
                        example: jane.doe@example.com
                      locale:
                        nullable: true
                        type: string
                        enum:
                          - sv-SE
                          - en-US
                        description: The locale for the observer. Can be overridden from the signing
                          room (if the observer_scope is 'viewer'), but this
                          value serves as the default if nothing else is
                          specified.
                      observer_scope:
                        type: string
                        enum:
                          - cc
                          - viewer
                        description: The scope of the observer. If specified as viewer, they will gain
                          access to the signing room to follow the process.
                          Otherwise, they will only receive the final, signed
                          document.
                      agreement:
                        type: string
                        format: cuid
                        description: The unique identifier for the agreement this observer belongs to
                        example: cp9tppmeltnhqeckzz3example
                      signing_room_url:
                        nullable: true
                        type: string
                        format: url
                        example: https://www.zigned.se/sign/cjecfacxrxzqd9def5zexample/cmakdfl6yfb9ls8h6jyexample
                        description: The URL to the signing room for the observer. Only available after
                          the agreement is not in draft.
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - name
                      - email
                      - observer_scope
                      - agreement
                      - signing_room_url
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: PUT /agreements/:agreement_id/observers/:observer_id Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Updates an existing observer.
      summary: Update an Observer
      tags:
        - Agreements
        - Observers
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: PUT /agreements/:agreement_id/observers/:observer_id parameter
          schema:
            type: string
            format: cuid
            example: chrptr5camqdstnchhvexample
        - name: observer_id
          in: path
          required: true
          description: PUT /agreements/:agreement_id/observers/:observer_id parameter
          schema:
            type: string
            format: cuid
            example: cte7k7scbsdd2a6zemsexample
      requestBody:
        description: PUT /agreements/:agreement_id/observers/:observer_id request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - allOf:
                                - type: object
                                  properties: {}
                                - type: object
                                  properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                          required: []
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    email:
                      type: string
                      format: email
                      description: The email of the ovserver. Required if observer_scope is "cc" or if
                        the agreement is configured to send emails.
                    name:
                      type: string
                      description: The name of the observer. If omitted, the email adress will be used
                        as name.
                    observer_scope:
                      type: string
                      enum:
                        - viewer
                        - cc
                      description: Either "viewer" or "cc". If the observer is a viewer, they will
                        gain access to the signing room. Otherwise they will
                        only receive a copy of the signed document.
                      default: viewer
                    locale:
                      type: string
                      enum:
                        - sv-SE
                        - en-US
                      default: sv-SE
                      description: Optional. The locale for the observer. Can be overridden by the
                        observer in the signing room (if observer_Scope is
                        'viewer'), but the locale provided by you will serve as
                        the default in initial communication. If not specified,
                        the default locale for the agreement will be used.
                  required: []
      security:
        - HTTP_1: []
    delete:
      operationId: DeleteAgreementsAgreementIdObserversObserverId
      responses:
        "200":
          description: DELETE /agreements/:agreement_id/observers/:observer_id Successful
            response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - deleted
                    description: Returns a single object of the observer resource which was deleted.
                  resource_type:
                    type: string
                    enum:
                      - observer
                    description: Data contains the observer resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the observer
                        example: cmxm8kdqkf9bxoalwinexample
                      resource_type:
                        type: string
                        enum:
                          - observer
                      name:
                        nullable: true
                        type: string
                        description: The name of the observer. Required if no email is provided.
                        example: Jane Doe
                      email:
                        nullable: true
                        type: string
                        description: The email of the observer. Required if agreement is configured to
                          send emails or if the observer_scope is 'cc'.
                        example: jane.doe@example.com
                      locale:
                        nullable: true
                        type: string
                        enum:
                          - sv-SE
                          - en-US
                        description: The locale for the observer. Can be overridden from the signing
                          room (if the observer_scope is 'viewer'), but this
                          value serves as the default if nothing else is
                          specified.
                      observer_scope:
                        type: string
                        enum:
                          - cc
                          - viewer
                        description: The scope of the observer. If specified as viewer, they will gain
                          access to the signing room to follow the process.
                          Otherwise, they will only receive the final, signed
                          document.
                      agreement:
                        type: string
                        format: cuid
                        description: The unique identifier for the agreement this observer belongs to
                        example: cp9tppmeltnhqeckzz3example
                      signing_room_url:
                        nullable: true
                        type: string
                        format: url
                        example: https://www.zigned.se/sign/cjecfacxrxzqd9def5zexample/cmakdfl6yfb9ls8h6jyexample
                        description: The URL to the signing room for the observer. Only available after
                          the agreement is not in draft.
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - name
                      - email
                      - observer_scope
                      - agreement
                      - signing_room_url
                      - created_at
                      - updated_at
                    description: The resource data that was deleted.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: DELETE /agreements/:agreement_id/observers/:observer_id Error
            response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Deletes an existing observer
      summary: Delete an Observer
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: DELETE /agreements/:agreement_id/observers/:observer_id parameter
          schema:
            type: string
            format: cuid
            example: cat7ahqqtzold28kdnuexample
        - name: observer_id
          in: path
          required: true
          description: DELETE /agreements/:agreement_id/observers/:observer_id parameter
          schema:
            type: string
            format: cuid
            example: ccpr5g60uvui5qrcl7kexample
      security:
        - HTTP_1: []
    get:
      operationId: GetAgreementsAgreementIdObserversObserverId
      responses:
        "200":
          description: GET /agreements/:agreement_id/observers/:observer_id Successful
            response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the observer resource.
                  resource_type:
                    type: string
                    enum:
                      - observer
                    description: Data contains the observer resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the observer
                        example: cmxm8kdqkf9bxoalwinexample
                      resource_type:
                        type: string
                        enum:
                          - observer
                      name:
                        nullable: true
                        type: string
                        description: The name of the observer. Required if no email is provided.
                        example: Jane Doe
                      email:
                        nullable: true
                        type: string
                        description: The email of the observer. Required if agreement is configured to
                          send emails or if the observer_scope is 'cc'.
                        example: jane.doe@example.com
                      locale:
                        nullable: true
                        type: string
                        enum:
                          - sv-SE
                          - en-US
                        description: The locale for the observer. Can be overridden from the signing
                          room (if the observer_scope is 'viewer'), but this
                          value serves as the default if nothing else is
                          specified.
                      observer_scope:
                        type: string
                        enum:
                          - cc
                          - viewer
                        description: The scope of the observer. If specified as viewer, they will gain
                          access to the signing room to follow the process.
                          Otherwise, they will only receive the final, signed
                          document.
                      agreement:
                        type: string
                        format: cuid
                        description: The unique identifier for the agreement this observer belongs to
                        example: cp9tppmeltnhqeckzz3example
                      signing_room_url:
                        nullable: true
                        type: string
                        format: url
                        example: https://www.zigned.se/sign/cjecfacxrxzqd9def5zexample/cmakdfl6yfb9ls8h6jyexample
                        description: The URL to the signing room for the observer. Only available after
                          the agreement is not in draft.
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - name
                      - email
                      - observer_scope
                      - agreement
                      - signing_room_url
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: GET /agreements/:agreement_id/observers/:observer_id Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Retrieves an observer of the Agreement.
      summary: Retrieve an Observer
      tags:
        - Agreements
        - Observers
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: GET /agreements/:agreement_id/observers/:observer_id parameter
          schema:
            type: string
            format: cuid
            example: cxx3btd5f2kxqpnymelexample
        - name: observer_id
          in: path
          required: true
          description: GET /agreements/:agreement_id/observers/:observer_id parameter
          schema:
            type: string
            format: cuid
            example: cjysltiifwgkl3pppthexample
      security:
        - HTTP_1: []
  /agreements/{agreement_id}/signing_groups:
    get:
      operationId: GetAgreementsAgreementIdSigningGroups
      responses:
        "200":
          description: GET /agreements/:agreement_id/signing_groups Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - list
                    description: A non-paginated list of the signing group resource.
                  resource_type:
                    type: string
                    enum:
                      - signing_group
                    description: Data contains the signing group resource.
                  data:
                    $ref: "#/components/schemas/d69cfbd1e408327b80080ee78c087563df3370f4"
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: GET /agreements/:agreement_id/signing_groups Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: List all Signing Groups of the agreement
      summary: List Signing Groups
      tags:
        - Agreements
        - Signing Groups
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: GET /agreements/:agreement_id/signing_groups parameter
          schema:
            type: string
            format: cuid
            example: cfrajiujwfq0zjzil4sexample
      security:
        - HTTP_1: []
    post:
      operationId: PostAgreementsAgreementIdSigningGroups
      responses:
        "200":
          description: POST /agreements/:agreement_id/signing_groups Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the signing_group resource.
                  resource_type:
                    type: string
                    enum:
                      - signing_group
                    description: Data contains the signing_group resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the signing group
                        example: cwpgsuuwu3wwysvhghwexample
                      resource_type:
                        type: string
                        enum:
                          - signing_group
                      name:
                        type: string
                        description: The name of the signing group
                        example: Board Members
                      status:
                        type: string
                        enum:
                          - draft
                          - pending
                          - fulfilled
                        description: The status of the signing group
                      order:
                        type: number
                        format: double
                        minimum: 5e-324
                        exclusiveMinimum: false
                        maximum: 1.7976931348623157e+308
                        exclusiveMaximum: false
                        description: The queue number of the signing group
                        example: 1
                      participants:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of IDs for the participants belonging to the signing group
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - $ref: "#/components/schemas/118cb3b11b8a1f3b6b1e60a89f96a8be9da32a0f"
                          - type: string
                            nullable: true
                            format: "null"
                      agreement:
                        type: string
                        format: cuid
                        description: The unique identifier of the agreement this signing group belongs
                          to
                        example: cqah6osvogc9vpeai9dexample
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - name
                      - status
                      - order
                      - participants
                      - agreement
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: POST /agreements/:agreement_id/signing_groups Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Signing groups are used to group participants when signing order is
        enabled. Signing order will be enabled automatically when you create
        your first signing group. All existing participants will be placed in
        the first group when the first signing group is created.
      summary: Create a signing group
      tags:
        - Agreements
        - Signing Groups
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: POST /agreements/:agreement_id/signing_groups parameter
          schema:
            type: string
            format: cuid
            example: co0v0xvn0xdfuw1oavaexample
      requestBody:
        description: POST /agreements/:agreement_id/signing_groups request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - allOf:
                                - type: object
                                  properties: {}
                                - type: object
                                  properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                          required: []
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    name:
                      type: string
                      description: The name of the signing group
                      example: Board members
                    order:
                      type: integer
                      format: int64
                      minimum: 0
                      exclusiveMinimum: true
                      maximum: 9007199254740991
                      exclusiveMaximum: false
                      description: The order of the signing group. If omitted, the signing group will
                        be added last in the signing order
                      example: 1
                    participants:
                      type: array
                      items:
                        type: string
                        format: cuid
                        minLength: 1
                      example: &a1
                        - c5lnvzb9saw7pkusnvcexample
                        - cgizx0nvpnyzxupx0cvexample
                        - codqlu3eiigxia664m3example
                      description: List of IDs for the participants you wish add to the signing group.
                        Be aware, if signing groups are used then all
                        participants must belong to a group. Any participant not
                        assigned to a group will be added to the last one in
                        order. Empty groups are deleted when the agreement is
                        finalized for signing.
                  required: []
      security:
        - HTTP_1: []
  /agreements/{agreement_id}/signing_groups/{signing_group_id}:
    get:
      operationId: GetAgreementsAgreementIdSigningGroupsSigningGroupId
      responses:
        "200":
          description: GET /agreements/:agreement_id/signing_groups/:signing_group_id
            Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the signing_group resource.
                  resource_type:
                    type: string
                    enum:
                      - signing_group
                    description: Data contains the signing_group resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the signing group
                        example: cwpgsuuwu3wwysvhghwexample
                      resource_type:
                        type: string
                        enum:
                          - signing_group
                      name:
                        type: string
                        description: The name of the signing group
                        example: Board Members
                      status:
                        type: string
                        enum:
                          - draft
                          - pending
                          - fulfilled
                        description: The status of the signing group
                      order:
                        type: number
                        format: double
                        minimum: 5e-324
                        exclusiveMinimum: false
                        maximum: 1.7976931348623157e+308
                        exclusiveMaximum: false
                        description: The queue number of the signing group
                        example: 1
                      participants:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of IDs for the participants belonging to the signing group
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - $ref: "#/components/schemas/118cb3b11b8a1f3b6b1e60a89f96a8be9da32a0f"
                          - type: string
                            nullable: true
                            format: "null"
                      agreement:
                        type: string
                        format: cuid
                        description: The unique identifier of the agreement this signing group belongs
                          to
                        example: cqah6osvogc9vpeai9dexample
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - name
                      - status
                      - order
                      - participants
                      - agreement
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: GET /agreements/:agreement_id/signing_groups/:signing_group_id
            Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Retrieves a single signing group with participants included
      summary: Retrieves a signing group
      tags:
        - Agreements
        - Signing Groups
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: GET /agreements/:agreement_id/signing_groups/:signing_group_id
            parameter
          schema:
            type: string
            format: cuid
            example: c9i1cxgkpzweteysr7wexample
        - name: signing_group_id
          in: path
          required: true
          description: GET /agreements/:agreement_id/signing_groups/:signing_group_id
            parameter
          schema:
            type: string
            format: cuid
            example: cdtwksdmjhhh0cijpvmexample
      security:
        - HTTP_1: []
    put:
      operationId: PutAgreementsAgreementIdSigningGroupsSigningGroupId
      responses:
        "200":
          description: PUT /agreements/:agreement_id/signing_groups/:signing_group_id
            Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the signing_group resource.
                  resource_type:
                    type: string
                    enum:
                      - signing_group
                    description: Data contains the signing_group resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the signing group
                        example: cwpgsuuwu3wwysvhghwexample
                      resource_type:
                        type: string
                        enum:
                          - signing_group
                      name:
                        type: string
                        description: The name of the signing group
                        example: Board Members
                      status:
                        type: string
                        enum:
                          - draft
                          - pending
                          - fulfilled
                        description: The status of the signing group
                      order:
                        type: number
                        format: double
                        minimum: 5e-324
                        exclusiveMinimum: false
                        maximum: 1.7976931348623157e+308
                        exclusiveMaximum: false
                        description: The queue number of the signing group
                        example: 1
                      participants:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of IDs for the participants belonging to the signing group
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - $ref: "#/components/schemas/118cb3b11b8a1f3b6b1e60a89f96a8be9da32a0f"
                          - type: string
                            nullable: true
                            format: "null"
                      agreement:
                        type: string
                        format: cuid
                        description: The unique identifier of the agreement this signing group belongs
                          to
                        example: cqah6osvogc9vpeai9dexample
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - name
                      - status
                      - order
                      - participants
                      - agreement
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: PUT /agreements/:agreement_id/signing_groups/:signing_group_id
            Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Update an existing signing group. The agreement must be in draft or
        open state.
      summary: Update a signing group
      tags:
        - Agreements
        - Signing Groups
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: PUT /agreements/:agreement_id/signing_groups/:signing_group_id
            parameter
          schema:
            type: string
            format: cuid
            example: cdzwzi4hwvovt2smzhwexample
        - name: signing_group_id
          in: path
          required: true
          description: PUT /agreements/:agreement_id/signing_groups/:signing_group_id
            parameter
          schema:
            type: string
            format: cuid
      requestBody:
        description: PUT /agreements/:agreement_id/signing_groups/:signing_group_id
          request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - allOf:
                                - type: object
                                  properties: {}
                                - type: object
                                  properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                          required: []
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    name:
                      type: string
                      example: Executive team
                    order:
                      type: integer
                      format: int64
                      minimum: 0
                      exclusiveMinimum: true
                      maximum: 9007199254740991
                      exclusiveMaximum: false
                      example: 2
                    participants:
                      type: array
                      items:
                        type: string
                        format: cuid
                        minLength: 1
                      example: *a1
                      description: List of IDs for the participants you wish add to the signing group.
                  required: []
      security:
        - HTTP_1: []
    delete:
      operationId: DeleteAgreementsAgreementIdSigningGroupsSigningGroupId
      responses:
        "200":
          description: DELETE /agreements/:agreement_id/signing_groups/:signing_group_id
            Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - deleted
                    description: Returns a single object of the signing_group resource which was
                      deleted.
                  resource_type:
                    type: string
                    enum:
                      - signing_group
                    description: Data contains the signing_group resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the signing group
                        example: cwpgsuuwu3wwysvhghwexample
                      resource_type:
                        type: string
                        enum:
                          - signing_group
                      name:
                        type: string
                        description: The name of the signing group
                        example: Board Members
                      status:
                        type: string
                        enum:
                          - draft
                          - pending
                          - fulfilled
                        description: The status of the signing group
                      order:
                        type: number
                        format: double
                        minimum: 5e-324
                        exclusiveMinimum: false
                        maximum: 1.7976931348623157e+308
                        exclusiveMaximum: false
                        description: The queue number of the signing group
                        example: 1
                      participants:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of IDs for the participants belonging to the signing group
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - $ref: "#/components/schemas/118cb3b11b8a1f3b6b1e60a89f96a8be9da32a0f"
                          - type: string
                            nullable: true
                            format: "null"
                      agreement:
                        type: string
                        format: cuid
                        description: The unique identifier of the agreement this signing group belongs
                          to
                        example: cqah6osvogc9vpeai9dexample
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - name
                      - status
                      - order
                      - participants
                      - agreement
                      - created_at
                      - updated_at
                    description: The resource data that was deleted.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: DELETE /agreements/:agreement_id/signing_groups/:signing_group_id
            Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Deletes a signing group from the agreement. The agreement must be
        in draft or open state.
      summary: Deletes a signing group
      tags:
        - Agreements
        - Signing Groups
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: DELETE /agreements/:agreement_id/signing_groups/:signing_group_id
            parameter
          schema:
            type: string
            format: cuid
            example: cdzwzi4hwvovt2smzhwexample
        - name: signing_group_id
          in: path
          required: true
          description: DELETE /agreements/:agreement_id/signing_groups/:signing_group_id
            parameter
          schema:
            type: string
            format: cuid
      security:
        - HTTP_1: []
  /agreements/{agreement_id}/documents/main:
    post:
      operationId: PostAgreementsAgreementIdDocumentsMain
      responses:
        "200":
          description: POST /agreements/:agreement_id/documents/main Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the agreement resource.
                  resource_type:
                    type: string
                    enum:
                      - agreement
                    description: Data contains the agreement resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the agreement
                        example: cckmmstwimwnfgqvuajexample
                      resource_type:
                        type: string
                        enum:
                          - agreement
                      test_mode:
                        type: boolean
                        description: Indicates if the agreement is created using a development client
                      status:
                        type: string
                        enum:
                          - draft
                          - pending
                          - fulfilled
                          - cancelled
                          - generating
                          - failed_to_generate
                          - open
                          - expired
                        description: The status of the agreement
                      trust_level:
                        type: string
                        enum:
                          - SES
                          - AES
                          - QES
                        description: The minimum trust level  for the signatures.
                      cancellation_reason:
                        nullable: true
                        type: string
                        description: If the agreement is in a cancelled state, this will be a short
                          description on the reason why, otherwise it will be
                          null.
                        example: null
                      theme:
                        oneOf:
                          - type: string
                            format: cuid
                            description: The unique identifier for the theme attached to the agreement
                            example: ccrirlws7dyjk2rzo2aexample
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - single
                                description: A single object of the theme resource.
                              resource_type:
                                type: string
                                enum:
                                  - theme
                                description: Data contains the theme resource.
                              data:
                                type: object
                                properties:
                                  id:
                                    type: string
                                    format: cuid
                                    description: The unique identifier of the theme
                                    example: coerir2amisfebqzdooexample
                                  resource_type:
                                    type: string
                                    enum:
                                      - theme
                                  logo:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                    description: The logo of the theme. This is displayed to the user in all
                                      communication and touch points.
                                  icon:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                    description: The icon of the theme. This is used for the favicon.
                                  primary_color:
                                    type: string
                                    default: "#000000"
                                    description: The primary color used to create the color palette in the signing
                                      room.
                                    example: "#000000"
                                  metadata:
                                    type: object
                                    properties:
                                      lookup_key:
                                        type: string
                                        description: A provided lookup key provided by you to help you identify the
                                          theme.
                                        example: your_internal_customer_id
                                    required:
                                      - lookup_key
                                  created_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                  updated_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                required:
                                  - id
                                  - resource_type
                                  - logo
                                  - icon
                                  - created_at
                                  - updated_at
                                description: The resource data.
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      issuer:
                        type: object
                        properties:
                          name:
                            nullable: true
                            type: string
                            description: The name of the issuer. Required if no email is provided.
                            example: John Doe
                          email:
                            nullable: true
                            type: string
                            description: The email of the issuer. Required if agreemnt is configured to send
                              emails.
                            example: example@example.com
                          role:
                            type: string
                            enum:
                              - signer
                              - approver
                              - observer
                            description: The role of the issuer in the agreement process.
                          participant_id:
                            type: string
                            format: cuid
                            description: If the issuer is a signer or approver this is the ID of the related
                              participant.
                            example: cd0jga4zijaebyga1wlexample
                          signing_room_url:
                            nullable: true
                            type: string
                            format: url
                            example: https://www.zigned.se/sign/cjecfacxrxzqd9def5zexample/cmakdfl6yfb9ls8h6jyexample
                            description: The URL to the signing room for the issuer. Only available after
                              the agreement has been finalized for signing.
                          locale:
                            nullable: true
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                            description: The locale for the issuer. Can be overridden from the signing room,
                              but this value serves as the default if nothing
                              else is specified. If omitted, the default_locale
                              of the agreement is used.
                        required:
                          - name
                          - email
                          - role
                          - signing_room_url
                        description: The issuer of the agreement
                      participants:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the participants belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the participant resource.
                              resource_type:
                                type: string
                                enum:
                                  - participant
                                description: Data contains the participant resource.
                              data:
                                $ref: "#/components/schemas/95c1af3f45da65daeedb661f70210b46b2bd71d5"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      observers:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the observers belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the observer resource.
                              resource_type:
                                type: string
                                enum:
                                  - observer
                                description: Data contains the observer resource.
                              data:
                                $ref: "#/components/schemas/c893c5c1d97a5bcbd8972ce188f48f8f75c6a171"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      signing_groups:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the signing groups belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the signing group resource.
                              resource_type:
                                type: string
                                enum:
                                  - signing_group
                                description: Data contains the signing group resource.
                              data:
                                $ref: "#/components/schemas/d69cfbd1e408327b80080ee78c087563df3370f4"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      documents:
                        type: object
                        properties:
                          original_documents:
                            type: object
                            properties:
                              main:
                                oneOf:
                                  - type: string
                                    format: cuid
                                    description: The unique identifier of the main document
                                    example: cmwqhs06osj0tus71kcexample
                                  - type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  - type: string
                                    nullable: true
                                    format: "null"
                                description: The main document which will be signed.
                              attachments:
                                oneOf:
                                  - type: array
                                    items:
                                      type: string
                                      format: cuid
                                      minLength: 1
                                    description: List of all IDs for the attachments belonging to this agreement
                                    example:
                                      - c5lnvzb9saw7pkusnvcexample
                                      - cgizx0nvpnyzxupx0cvexample
                                      - codqlu3eiigxia664m3example
                                  - type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the attachment resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - attachment
                                        description: Data contains the attachment resource.
                                      data:
                                        $ref: "#/components/schemas/18aea1f88c852890888d309ddd8605d8c0438d2b"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  - type: string
                                    nullable: true
                                    format: "null"
                            required:
                              - main
                          signed_document:
                            oneOf:
                              - type: string
                                format: cuid
                                description: The unique identifier for the signed document
                                example: ckfd2sygk12n9slxwkeexample
                              - type: object
                                properties:
                                  version:
                                    type: string
                                    enum:
                                      - "1.0"
                                    description: The version of the response schema
                                  result_type:
                                    type: string
                                    enum:
                                      - single
                                    description: A single object of the file resource.
                                  resource_type:
                                    type: string
                                    enum:
                                      - file
                                    description: Data contains the file resource.
                                  data:
                                    type: object
                                    properties:
                                      id:
                                        type: string
                                        format: cuid
                                        description: The unique identifier of the file
                                        example: cytp5m6ijs4rxs0erqsexample
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                      filename:
                                        type: string
                                        minLength: 1
                                        description: The complete filename including the file extension
                                        example: my-file.pdf
                                      mime_type:
                                        type: string
                                        minLength: 1
                                        description: The mime type of the file
                                        example: application/pdf
                                      url:
                                        type: string
                                        format: url
                                        description: The signed read url of the file
                                        example: https://zigned.se
                                      metadata:
                                        type: object
                                        properties:
                                          lookup_key:
                                            type: string
                                            description: A provided lookup key provided by you to help you identify the
                                              file.
                                            example: file_tag
                                        required:
                                          - lookup_key
                                      created_at:
                                        type: string
                                        description: UTC datetime ISO string
                                        example: 2024-01-01T00:00:00.000Z
                                      updated_at:
                                        type: string
                                        description: UTC datetime ISO string
                                        example: 2024-01-01T00:00:00.000Z
                                    required:
                                      - id
                                      - resource_type
                                      - filename
                                      - mime_type
                                      - created_at
                                      - updated_at
                                    description: The resource data.
                                required:
                                  - version
                                  - result_type
                                  - resource_type
                                  - data
                              - type: string
                                nullable: true
                                format: "null"
                            description: The finalized and signed document.
                        required:
                          - original_documents
                          - signed_document
                      signing_order:
                        type: object
                        properties:
                          enabled:
                            type: boolean
                          grouped:
                            type: boolean
                        required:
                          - enabled
                          - grouped
                      communication:
                        type: object
                        properties:
                          send_emails:
                            type: boolean
                          default_locale:
                            nullable: true
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                            description: The default locale for the agreement. Can be overridden by
                              individual participants/observers from the signing
                              room, but this value serves as the default if
                              nothing else is specified.
                          automatic_reminders:
                            type: object
                            properties:
                              enabled:
                                type: boolean
                              intensity:
                                nullable: true
                                type: string
                                enum:
                                  - intense
                                  - normal
                                description: The intensity of the reminders. The reminders are scheduled with an
                                  exponential fall off, but the intensity
                                  regulates the base interval. If expiration
                                  date is set for the agreement, the reminders
                                  become more intense at the end.
                            required:
                              - enabled
                              - intensity
                          recipient_messages:
                            nullable: true
                            type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - single
                                description: A single object of the recipient_message resource.
                              resource_type:
                                type: string
                                enum:
                                  - recipient_message
                                description: Data contains the recipient_message resource.
                              data:
                                type: object
                                properties:
                                  id:
                                    type: string
                                    format: cuid
                                    description: The unique identifier of the recipient message
                                    example: ck1ayqgg0fuxdetcvjtexample
                                  resource_type:
                                    type: string
                                    enum:
                                      - recipient_message
                                  message_templates:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the recipient message template resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - recipient_message_template
                                        description: Data contains the recipient message template resource.
                                      data:
                                        $ref: "#/components/schemas/7aadbd48657236af70d97541a9c85c00b14e95a5"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  message_template_variables:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the recipient message template variable
                                          resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - recipient_message_template_variable
                                        description: Data contains the recipient message template variable resource.
                                      data:
                                        $ref: "#/components/schemas/f9a847cbdf0e167d1aa8d3b7127afb96d878e823"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  created_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                  updated_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                required:
                                  - id
                                  - resource_type
                                  - message_templates
                                  - message_template_variables
                                  - created_at
                                  - updated_at
                                description: The resource data.
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                        required:
                          - send_emails
                      metadata:
                        type: object
                        properties:
                          mask_pii:
                            type: boolean
                            default: true
                            description: Whether to mask PII visually on the signed document. Default is
                              true. Note that this only affects the visual
                              representation of the PII, the actual PII is still
                              present in the evidence package or certificate.
                          lookup_key:
                            type: string
                            description: A provided lookup key provided by you to help you identify the
                              agreement.
                            example: your_internal_customer_id
                          success_callback_url:
                            type: string
                            format: url
                            description: A provided callback url to refer the participants back to post
                              successful action.
                            example: https://yourdomain.com/sign-complete
                      expires_at:
                        nullable: true
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      delete_scheduled_at:
                        nullable: true
                        type: string
                        description: The timestamp when deletion is scheduled to occur. Null if not
                          scheduled.
                        example: 2024-01-01T00:00:00.000Z
                      deleted_at:
                        nullable: true
                        type: string
                        description: The timestamp when the agreement was deleted. Null if not deleted.
                        example: 2024-01-01T00:00:00.000Z
                      deleted:
                        type: boolean
                        description: Whether the agreement has been deleted. Returns true if either
                          scheduled for deletion or if already deleted.
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - test_mode
                      - status
                      - cancellation_reason
                      - theme
                      - issuer
                      - participants
                      - signing_order
                      - communication
                      - updated_at
                      - created_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: POST /agreements/:agreement_id/documents/main Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Attaches the main document to be signed. The document must be
        uploaded first to your files archive. When attaching a document to be
        signed, it will be cloned and become immutable.
      summary: Attach the Main Document
      tags:
        - Agreements
        - Documents
        - Main
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: POST /agreements/:agreement_id/documents/main parameter
          schema:
            type: string
            format: cuid
            example: clwb1sv6uycmzd2jdg6example
      requestBody:
        description: POST /agreements/:agreement_id/documents/main request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - allOf:
                                - type: object
                                  properties: {}
                                - type: object
                                  properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                          required: []
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    file_id:
                      type: string
                      format: cuid
                      example: cvq1g01dmou5b611pxbexample
                  required:
                    - file_id
      security:
        - HTTP_1: []
    delete:
      operationId: DeleteAgreementsAgreementIdDocumentsMain
      responses:
        "200":
          description: DELETE /agreements/:agreement_id/documents/main Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the agreement resource.
                  resource_type:
                    type: string
                    enum:
                      - agreement
                    description: Data contains the agreement resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the agreement
                        example: cckmmstwimwnfgqvuajexample
                      resource_type:
                        type: string
                        enum:
                          - agreement
                      test_mode:
                        type: boolean
                        description: Indicates if the agreement is created using a development client
                      status:
                        type: string
                        enum:
                          - draft
                          - pending
                          - fulfilled
                          - cancelled
                          - generating
                          - failed_to_generate
                          - open
                          - expired
                        description: The status of the agreement
                      trust_level:
                        type: string
                        enum:
                          - SES
                          - AES
                          - QES
                        description: The minimum trust level  for the signatures.
                      cancellation_reason:
                        nullable: true
                        type: string
                        description: If the agreement is in a cancelled state, this will be a short
                          description on the reason why, otherwise it will be
                          null.
                        example: null
                      theme:
                        oneOf:
                          - type: string
                            format: cuid
                            description: The unique identifier for the theme attached to the agreement
                            example: ccrirlws7dyjk2rzo2aexample
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - single
                                description: A single object of the theme resource.
                              resource_type:
                                type: string
                                enum:
                                  - theme
                                description: Data contains the theme resource.
                              data:
                                type: object
                                properties:
                                  id:
                                    type: string
                                    format: cuid
                                    description: The unique identifier of the theme
                                    example: coerir2amisfebqzdooexample
                                  resource_type:
                                    type: string
                                    enum:
                                      - theme
                                  logo:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                    description: The logo of the theme. This is displayed to the user in all
                                      communication and touch points.
                                  icon:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                    description: The icon of the theme. This is used for the favicon.
                                  primary_color:
                                    type: string
                                    default: "#000000"
                                    description: The primary color used to create the color palette in the signing
                                      room.
                                    example: "#000000"
                                  metadata:
                                    type: object
                                    properties:
                                      lookup_key:
                                        type: string
                                        description: A provided lookup key provided by you to help you identify the
                                          theme.
                                        example: your_internal_customer_id
                                    required:
                                      - lookup_key
                                  created_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                  updated_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                required:
                                  - id
                                  - resource_type
                                  - logo
                                  - icon
                                  - created_at
                                  - updated_at
                                description: The resource data.
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      issuer:
                        type: object
                        properties:
                          name:
                            nullable: true
                            type: string
                            description: The name of the issuer. Required if no email is provided.
                            example: John Doe
                          email:
                            nullable: true
                            type: string
                            description: The email of the issuer. Required if agreemnt is configured to send
                              emails.
                            example: example@example.com
                          role:
                            type: string
                            enum:
                              - signer
                              - approver
                              - observer
                            description: The role of the issuer in the agreement process.
                          participant_id:
                            type: string
                            format: cuid
                            description: If the issuer is a signer or approver this is the ID of the related
                              participant.
                            example: cd0jga4zijaebyga1wlexample
                          signing_room_url:
                            nullable: true
                            type: string
                            format: url
                            example: https://www.zigned.se/sign/cjecfacxrxzqd9def5zexample/cmakdfl6yfb9ls8h6jyexample
                            description: The URL to the signing room for the issuer. Only available after
                              the agreement has been finalized for signing.
                          locale:
                            nullable: true
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                            description: The locale for the issuer. Can be overridden from the signing room,
                              but this value serves as the default if nothing
                              else is specified. If omitted, the default_locale
                              of the agreement is used.
                        required:
                          - name
                          - email
                          - role
                          - signing_room_url
                        description: The issuer of the agreement
                      participants:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the participants belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the participant resource.
                              resource_type:
                                type: string
                                enum:
                                  - participant
                                description: Data contains the participant resource.
                              data:
                                $ref: "#/components/schemas/95c1af3f45da65daeedb661f70210b46b2bd71d5"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      observers:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the observers belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the observer resource.
                              resource_type:
                                type: string
                                enum:
                                  - observer
                                description: Data contains the observer resource.
                              data:
                                $ref: "#/components/schemas/c893c5c1d97a5bcbd8972ce188f48f8f75c6a171"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      signing_groups:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the signing groups belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the signing group resource.
                              resource_type:
                                type: string
                                enum:
                                  - signing_group
                                description: Data contains the signing group resource.
                              data:
                                $ref: "#/components/schemas/d69cfbd1e408327b80080ee78c087563df3370f4"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      documents:
                        type: object
                        properties:
                          original_documents:
                            type: object
                            properties:
                              main:
                                oneOf:
                                  - type: string
                                    format: cuid
                                    description: The unique identifier of the main document
                                    example: cmwqhs06osj0tus71kcexample
                                  - type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  - type: string
                                    nullable: true
                                    format: "null"
                                description: The main document which will be signed.
                              attachments:
                                oneOf:
                                  - type: array
                                    items:
                                      type: string
                                      format: cuid
                                      minLength: 1
                                    description: List of all IDs for the attachments belonging to this agreement
                                    example:
                                      - c5lnvzb9saw7pkusnvcexample
                                      - cgizx0nvpnyzxupx0cvexample
                                      - codqlu3eiigxia664m3example
                                  - type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the attachment resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - attachment
                                        description: Data contains the attachment resource.
                                      data:
                                        $ref: "#/components/schemas/18aea1f88c852890888d309ddd8605d8c0438d2b"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  - type: string
                                    nullable: true
                                    format: "null"
                            required:
                              - main
                          signed_document:
                            oneOf:
                              - type: string
                                format: cuid
                                description: The unique identifier for the signed document
                                example: ckfd2sygk12n9slxwkeexample
                              - type: object
                                properties:
                                  version:
                                    type: string
                                    enum:
                                      - "1.0"
                                    description: The version of the response schema
                                  result_type:
                                    type: string
                                    enum:
                                      - single
                                    description: A single object of the file resource.
                                  resource_type:
                                    type: string
                                    enum:
                                      - file
                                    description: Data contains the file resource.
                                  data:
                                    type: object
                                    properties:
                                      id:
                                        type: string
                                        format: cuid
                                        description: The unique identifier of the file
                                        example: cytp5m6ijs4rxs0erqsexample
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                      filename:
                                        type: string
                                        minLength: 1
                                        description: The complete filename including the file extension
                                        example: my-file.pdf
                                      mime_type:
                                        type: string
                                        minLength: 1
                                        description: The mime type of the file
                                        example: application/pdf
                                      url:
                                        type: string
                                        format: url
                                        description: The signed read url of the file
                                        example: https://zigned.se
                                      metadata:
                                        type: object
                                        properties:
                                          lookup_key:
                                            type: string
                                            description: A provided lookup key provided by you to help you identify the
                                              file.
                                            example: file_tag
                                        required:
                                          - lookup_key
                                      created_at:
                                        type: string
                                        description: UTC datetime ISO string
                                        example: 2024-01-01T00:00:00.000Z
                                      updated_at:
                                        type: string
                                        description: UTC datetime ISO string
                                        example: 2024-01-01T00:00:00.000Z
                                    required:
                                      - id
                                      - resource_type
                                      - filename
                                      - mime_type
                                      - created_at
                                      - updated_at
                                    description: The resource data.
                                required:
                                  - version
                                  - result_type
                                  - resource_type
                                  - data
                              - type: string
                                nullable: true
                                format: "null"
                            description: The finalized and signed document.
                        required:
                          - original_documents
                          - signed_document
                      signing_order:
                        type: object
                        properties:
                          enabled:
                            type: boolean
                          grouped:
                            type: boolean
                        required:
                          - enabled
                          - grouped
                      communication:
                        type: object
                        properties:
                          send_emails:
                            type: boolean
                          default_locale:
                            nullable: true
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                            description: The default locale for the agreement. Can be overridden by
                              individual participants/observers from the signing
                              room, but this value serves as the default if
                              nothing else is specified.
                          automatic_reminders:
                            type: object
                            properties:
                              enabled:
                                type: boolean
                              intensity:
                                nullable: true
                                type: string
                                enum:
                                  - intense
                                  - normal
                                description: The intensity of the reminders. The reminders are scheduled with an
                                  exponential fall off, but the intensity
                                  regulates the base interval. If expiration
                                  date is set for the agreement, the reminders
                                  become more intense at the end.
                            required:
                              - enabled
                              - intensity
                          recipient_messages:
                            nullable: true
                            type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - single
                                description: A single object of the recipient_message resource.
                              resource_type:
                                type: string
                                enum:
                                  - recipient_message
                                description: Data contains the recipient_message resource.
                              data:
                                type: object
                                properties:
                                  id:
                                    type: string
                                    format: cuid
                                    description: The unique identifier of the recipient message
                                    example: ck1ayqgg0fuxdetcvjtexample
                                  resource_type:
                                    type: string
                                    enum:
                                      - recipient_message
                                  message_templates:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the recipient message template resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - recipient_message_template
                                        description: Data contains the recipient message template resource.
                                      data:
                                        $ref: "#/components/schemas/7aadbd48657236af70d97541a9c85c00b14e95a5"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  message_template_variables:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the recipient message template variable
                                          resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - recipient_message_template_variable
                                        description: Data contains the recipient message template variable resource.
                                      data:
                                        $ref: "#/components/schemas/f9a847cbdf0e167d1aa8d3b7127afb96d878e823"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  created_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                  updated_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                required:
                                  - id
                                  - resource_type
                                  - message_templates
                                  - message_template_variables
                                  - created_at
                                  - updated_at
                                description: The resource data.
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                        required:
                          - send_emails
                      metadata:
                        type: object
                        properties:
                          mask_pii:
                            type: boolean
                            default: true
                            description: Whether to mask PII visually on the signed document. Default is
                              true. Note that this only affects the visual
                              representation of the PII, the actual PII is still
                              present in the evidence package or certificate.
                          lookup_key:
                            type: string
                            description: A provided lookup key provided by you to help you identify the
                              agreement.
                            example: your_internal_customer_id
                          success_callback_url:
                            type: string
                            format: url
                            description: A provided callback url to refer the participants back to post
                              successful action.
                            example: https://yourdomain.com/sign-complete
                      expires_at:
                        nullable: true
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      delete_scheduled_at:
                        nullable: true
                        type: string
                        description: The timestamp when deletion is scheduled to occur. Null if not
                          scheduled.
                        example: 2024-01-01T00:00:00.000Z
                      deleted_at:
                        nullable: true
                        type: string
                        description: The timestamp when the agreement was deleted. Null if not deleted.
                        example: 2024-01-01T00:00:00.000Z
                      deleted:
                        type: boolean
                        description: Whether the agreement has been deleted. Returns true if either
                          scheduled for deletion or if already deleted.
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - test_mode
                      - status
                      - cancellation_reason
                      - theme
                      - issuer
                      - participants
                      - signing_order
                      - communication
                      - updated_at
                      - created_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: DELETE /agreements/:agreement_id/documents/main Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Deletes and detaches the main document from the agreement. The
        document will not be deleted from your files archive.
      summary: Detach the Main Document
      tags:
        - Agreements
        - Documents
        - Main
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: DELETE /agreements/:agreement_id/documents/main parameter
          schema:
            type: string
            format: cuid
            example: ctugdx2t1tckqjica4aexample
      security:
        - HTTP_1: []
  /agreements/{agreement_id}/documents/attachments:
    post:
      operationId: PostAgreementsAgreementIdDocumentsAttachments
      responses:
        "200":
          description: POST /agreements/:agreement_id/documents/attachments Successful
            response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the attachment resource.
                  resource_type:
                    type: string
                    enum:
                      - attachment
                    description: Data contains the attachment resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the attachment
                        example: cceyporub5ufunzbc3wexample
                      resource_type:
                        type: string
                        enum:
                          - attachment
                      agreement:
                        type: string
                        format: cuid
                        description: The unique identifier of the agreement which this attachment
                          belongs to
                        example: cljzatjzjjnjdsdzbf5example
                      order:
                        type: integer
                        format: int64
                        minimum: 0
                        exclusiveMinimum: true
                        maximum: 9007199254740991
                        exclusiveMaximum: false
                        description: The order of this attachment relative to the other attachments
                        example: 1
                      file:
                        oneOf:
                          - type: string
                            format: cuid
                            description: The unique identifier for the attached document
                            example: ci3bkfyapgl4srrtji9example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - single
                                description: A single object of the file resource.
                              resource_type:
                                type: string
                                enum:
                                  - file
                                description: Data contains the file resource.
                              data:
                                type: object
                                properties:
                                  id:
                                    type: string
                                    format: cuid
                                    description: The unique identifier of the file
                                    example: cytp5m6ijs4rxs0erqsexample
                                  resource_type:
                                    type: string
                                    enum:
                                      - file
                                  filename:
                                    type: string
                                    minLength: 1
                                    description: The complete filename including the file extension
                                    example: my-file.pdf
                                  mime_type:
                                    type: string
                                    minLength: 1
                                    description: The mime type of the file
                                    example: application/pdf
                                  url:
                                    type: string
                                    format: url
                                    description: The signed read url of the file
                                    example: https://zigned.se
                                  metadata:
                                    type: object
                                    properties:
                                      lookup_key:
                                        type: string
                                        description: A provided lookup key provided by you to help you identify the
                                          file.
                                        example: file_tag
                                    required:
                                      - lookup_key
                                  created_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                  updated_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                required:
                                  - id
                                  - resource_type
                                  - filename
                                  - mime_type
                                  - created_at
                                  - updated_at
                                description: The resource data.
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - agreement
                      - order
                      - file
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: POST /agreements/:agreement_id/documents/attachments Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Add an attachment for the agreement. Attachments are supplemental
        documents for the agreement. You can specify the order in which they are
        presented. If not specified they will be added at the end.
      summary: Add an attachment
      tags:
        - Agreements
        - Documents
        - Attachments
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: POST /agreements/:agreement_id/documents/attachments parameter
          schema:
            type: string
            format: cuid
            example: cylvvzv3ss2egpubt2qexample
      requestBody:
        description: POST /agreements/:agreement_id/documents/attachments request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - allOf:
                                - type: object
                                  properties: {}
                                - type: object
                                  properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                          required: []
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    file_id:
                      type: string
                      format: cuid
                      example: ctwlclrihqjemuavharexample
                    order:
                      type: integer
                      format: int64
                      minimum: -9007199254740991
                      exclusiveMinimum: false
                      maximum: 9007199254740991
                      exclusiveMaximum: false
                      example: 1
                  required:
                    - file_id
      security:
        - HTTP_1: []
    get:
      operationId: GetAgreementsAgreementIdDocumentsAttachments
      responses:
        "200":
          description: GET /agreements/:agreement_id/documents/attachments Successful
            response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - list
                    description: A non-paginated list of the attachment resource.
                  resource_type:
                    type: string
                    enum:
                      - attachment
                    description: Data contains the attachment resource.
                  data:
                    $ref: "#/components/schemas/18aea1f88c852890888d309ddd8605d8c0438d2b"
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: GET /agreements/:agreement_id/documents/attachments Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: List all attachments for the agreement
      summary: List attachments
      tags:
        - Agreements
        - Documents
        - Attachments
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: GET /agreements/:agreement_id/documents/attachments parameter
          schema:
            type: string
            format: cuid
            example: cz75aprvz2vpz9j9qsiexample
      security:
        - HTTP_1: []
  /agreements/{agreement_id}/documents/attachments/{attachment_id}:
    put:
      operationId: PutAgreementsAgreementIdDocumentsAttachmentsAttachmentId
      responses:
        "200":
          description: PUT /agreements/:agreement_id/documents/attachments/:attachment_id
            Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the attachment resource.
                  resource_type:
                    type: string
                    enum:
                      - attachment
                    description: Data contains the attachment resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the attachment
                        example: cceyporub5ufunzbc3wexample
                      resource_type:
                        type: string
                        enum:
                          - attachment
                      agreement:
                        type: string
                        format: cuid
                        description: The unique identifier of the agreement which this attachment
                          belongs to
                        example: cljzatjzjjnjdsdzbf5example
                      order:
                        type: integer
                        format: int64
                        minimum: 0
                        exclusiveMinimum: true
                        maximum: 9007199254740991
                        exclusiveMaximum: false
                        description: The order of this attachment relative to the other attachments
                        example: 1
                      file:
                        oneOf:
                          - type: string
                            format: cuid
                            description: The unique identifier for the attached document
                            example: ci3bkfyapgl4srrtji9example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - single
                                description: A single object of the file resource.
                              resource_type:
                                type: string
                                enum:
                                  - file
                                description: Data contains the file resource.
                              data:
                                type: object
                                properties:
                                  id:
                                    type: string
                                    format: cuid
                                    description: The unique identifier of the file
                                    example: cytp5m6ijs4rxs0erqsexample
                                  resource_type:
                                    type: string
                                    enum:
                                      - file
                                  filename:
                                    type: string
                                    minLength: 1
                                    description: The complete filename including the file extension
                                    example: my-file.pdf
                                  mime_type:
                                    type: string
                                    minLength: 1
                                    description: The mime type of the file
                                    example: application/pdf
                                  url:
                                    type: string
                                    format: url
                                    description: The signed read url of the file
                                    example: https://zigned.se
                                  metadata:
                                    type: object
                                    properties:
                                      lookup_key:
                                        type: string
                                        description: A provided lookup key provided by you to help you identify the
                                          file.
                                        example: file_tag
                                    required:
                                      - lookup_key
                                  created_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                  updated_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                required:
                                  - id
                                  - resource_type
                                  - filename
                                  - mime_type
                                  - created_at
                                  - updated_at
                                description: The resource data.
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - agreement
                      - order
                      - file
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: PUT /agreements/:agreement_id/documents/attachments/:attachment_id
            Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Update an attachment for the agreement
      summary: Update an Attachment
      tags:
        - Agreements
        - Documents
        - Attachments
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: PUT /agreements/:agreement_id/documents/attachments/:attachment_id
            parameter
          schema:
            type: string
            format: cuid
            example: ce9tnxoi8m3ythbbagpexample
        - name: attachment_id
          in: path
          required: true
          description: PUT /agreements/:agreement_id/documents/attachments/:attachment_id
            parameter
          schema:
            type: string
            format: cuid
            example: cmkbd3my3btvwcoonrsexample
      requestBody:
        description: PUT /agreements/:agreement_id/documents/attachments/:attachment_id
          request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - allOf:
                                - type: object
                                  properties: {}
                                - type: object
                                  properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                          required: []
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    order:
                      type: integer
                      format: int64
                      minimum: 0
                      exclusiveMinimum: true
                      maximum: 9007199254740991
                      exclusiveMaximum: false
                      example: 2
                  required:
                    - order
      security:
        - HTTP_1: []
    get:
      operationId: GetAgreementsAgreementIdDocumentsAttachmentsAttachmentId
      responses:
        "200":
          description: GET /agreements/:agreement_id/documents/attachments/:attachment_id
            Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the attachment resource.
                  resource_type:
                    type: string
                    enum:
                      - attachment
                    description: Data contains the attachment resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the attachment
                        example: cceyporub5ufunzbc3wexample
                      resource_type:
                        type: string
                        enum:
                          - attachment
                      agreement:
                        type: string
                        format: cuid
                        description: The unique identifier of the agreement which this attachment
                          belongs to
                        example: cljzatjzjjnjdsdzbf5example
                      order:
                        type: integer
                        format: int64
                        minimum: 0
                        exclusiveMinimum: true
                        maximum: 9007199254740991
                        exclusiveMaximum: false
                        description: The order of this attachment relative to the other attachments
                        example: 1
                      file:
                        oneOf:
                          - type: string
                            format: cuid
                            description: The unique identifier for the attached document
                            example: ci3bkfyapgl4srrtji9example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - single
                                description: A single object of the file resource.
                              resource_type:
                                type: string
                                enum:
                                  - file
                                description: Data contains the file resource.
                              data:
                                type: object
                                properties:
                                  id:
                                    type: string
                                    format: cuid
                                    description: The unique identifier of the file
                                    example: cytp5m6ijs4rxs0erqsexample
                                  resource_type:
                                    type: string
                                    enum:
                                      - file
                                  filename:
                                    type: string
                                    minLength: 1
                                    description: The complete filename including the file extension
                                    example: my-file.pdf
                                  mime_type:
                                    type: string
                                    minLength: 1
                                    description: The mime type of the file
                                    example: application/pdf
                                  url:
                                    type: string
                                    format: url
                                    description: The signed read url of the file
                                    example: https://zigned.se
                                  metadata:
                                    type: object
                                    properties:
                                      lookup_key:
                                        type: string
                                        description: A provided lookup key provided by you to help you identify the
                                          file.
                                        example: file_tag
                                    required:
                                      - lookup_key
                                  created_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                  updated_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                required:
                                  - id
                                  - resource_type
                                  - filename
                                  - mime_type
                                  - created_at
                                  - updated_at
                                description: The resource data.
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - agreement
                      - order
                      - file
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: GET /agreements/:agreement_id/documents/attachments/:attachment_id
            Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Retrieve a single attachment for the agreement
      summary: Retrieve an Attachment
      tags:
        - Agreements
        - Documents
        - Attachments
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: GET /agreements/:agreement_id/documents/attachments/:attachment_id
            parameter
          schema:
            type: string
            format: cuid
            example: cuaehsp19x448nkdd14example
        - name: attachment_id
          in: path
          required: true
          description: GET /agreements/:agreement_id/documents/attachments/:attachment_id
            parameter
          schema:
            type: string
            format: cuid
            example: ch3i5dgdt0zb2pdkxtsexample
      security:
        - HTTP_1: []
    delete:
      operationId: DeleteAgreementsAgreementIdDocumentsAttachmentsAttachmentId
      responses:
        "200":
          description: DELETE
            /agreements/:agreement_id/documents/attachments/:attachment_id
            Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - deleted
                    description: Returns a single object of the attachment resource which was
                      deleted.
                  resource_type:
                    type: string
                    enum:
                      - attachment
                    description: Data contains the attachment resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the attachment
                        example: cceyporub5ufunzbc3wexample
                      resource_type:
                        type: string
                        enum:
                          - attachment
                      agreement:
                        type: string
                        format: cuid
                        description: The unique identifier of the agreement which this attachment
                          belongs to
                        example: cljzatjzjjnjdsdzbf5example
                      order:
                        type: integer
                        format: int64
                        minimum: 0
                        exclusiveMinimum: true
                        maximum: 9007199254740991
                        exclusiveMaximum: false
                        description: The order of this attachment relative to the other attachments
                        example: 1
                      file:
                        oneOf:
                          - type: string
                            format: cuid
                            description: The unique identifier for the attached document
                            example: ci3bkfyapgl4srrtji9example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - single
                                description: A single object of the file resource.
                              resource_type:
                                type: string
                                enum:
                                  - file
                                description: Data contains the file resource.
                              data:
                                type: object
                                properties:
                                  id:
                                    type: string
                                    format: cuid
                                    description: The unique identifier of the file
                                    example: cytp5m6ijs4rxs0erqsexample
                                  resource_type:
                                    type: string
                                    enum:
                                      - file
                                  filename:
                                    type: string
                                    minLength: 1
                                    description: The complete filename including the file extension
                                    example: my-file.pdf
                                  mime_type:
                                    type: string
                                    minLength: 1
                                    description: The mime type of the file
                                    example: application/pdf
                                  url:
                                    type: string
                                    format: url
                                    description: The signed read url of the file
                                    example: https://zigned.se
                                  metadata:
                                    type: object
                                    properties:
                                      lookup_key:
                                        type: string
                                        description: A provided lookup key provided by you to help you identify the
                                          file.
                                        example: file_tag
                                    required:
                                      - lookup_key
                                  created_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                  updated_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                required:
                                  - id
                                  - resource_type
                                  - filename
                                  - mime_type
                                  - created_at
                                  - updated_at
                                description: The resource data.
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - agreement
                      - order
                      - file
                      - created_at
                      - updated_at
                    description: The resource data that was deleted.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: DELETE
            /agreements/:agreement_id/documents/attachments/:attachment_id Error
            response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Detaches and deletes an attachment from the agreement. The
        attachment order will be updated accordingly.
      summary: Delete an Attachment
      tags:
        - Agreements
        - Documents
        - Attachments
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: DELETE
            /agreements/:agreement_id/documents/attachments/:attachment_id
            parameter
          schema:
            type: string
            format: cuid
            example: cjl4e2tyqynbqwymfkoexample
        - name: attachment_id
          in: path
          required: true
          description: DELETE
            /agreements/:agreement_id/documents/attachments/:attachment_id
            parameter
          schema:
            type: string
            format: cuid
            example: cqal7qurrrnxokskspyexample
      security:
        - HTTP_1: []
  /agreements/{agreement_id}/lifecycle:
    post:
      operationId: PostAgreementsAgreementIdLifecycle
      responses:
        "200":
          description: POST /agreements/:agreement_id/lifecycle Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the agreement resource.
                  resource_type:
                    type: string
                    enum:
                      - agreement
                    description: Data contains the agreement resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the agreement
                        example: cckmmstwimwnfgqvuajexample
                      resource_type:
                        type: string
                        enum:
                          - agreement
                      test_mode:
                        type: boolean
                        description: Indicates if the agreement is created using a development client
                      status:
                        type: string
                        enum:
                          - draft
                          - pending
                          - fulfilled
                          - cancelled
                          - generating
                          - failed_to_generate
                          - open
                          - expired
                        description: The status of the agreement
                      trust_level:
                        type: string
                        enum:
                          - SES
                          - AES
                          - QES
                        description: The minimum trust level  for the signatures.
                      cancellation_reason:
                        nullable: true
                        type: string
                        description: If the agreement is in a cancelled state, this will be a short
                          description on the reason why, otherwise it will be
                          null.
                        example: null
                      theme:
                        oneOf:
                          - type: string
                            format: cuid
                            description: The unique identifier for the theme attached to the agreement
                            example: ccrirlws7dyjk2rzo2aexample
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - single
                                description: A single object of the theme resource.
                              resource_type:
                                type: string
                                enum:
                                  - theme
                                description: Data contains the theme resource.
                              data:
                                type: object
                                properties:
                                  id:
                                    type: string
                                    format: cuid
                                    description: The unique identifier of the theme
                                    example: coerir2amisfebqzdooexample
                                  resource_type:
                                    type: string
                                    enum:
                                      - theme
                                  logo:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                    description: The logo of the theme. This is displayed to the user in all
                                      communication and touch points.
                                  icon:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                    description: The icon of the theme. This is used for the favicon.
                                  primary_color:
                                    type: string
                                    default: "#000000"
                                    description: The primary color used to create the color palette in the signing
                                      room.
                                    example: "#000000"
                                  metadata:
                                    type: object
                                    properties:
                                      lookup_key:
                                        type: string
                                        description: A provided lookup key provided by you to help you identify the
                                          theme.
                                        example: your_internal_customer_id
                                    required:
                                      - lookup_key
                                  created_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                  updated_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                required:
                                  - id
                                  - resource_type
                                  - logo
                                  - icon
                                  - created_at
                                  - updated_at
                                description: The resource data.
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      issuer:
                        type: object
                        properties:
                          name:
                            nullable: true
                            type: string
                            description: The name of the issuer. Required if no email is provided.
                            example: John Doe
                          email:
                            nullable: true
                            type: string
                            description: The email of the issuer. Required if agreemnt is configured to send
                              emails.
                            example: example@example.com
                          role:
                            type: string
                            enum:
                              - signer
                              - approver
                              - observer
                            description: The role of the issuer in the agreement process.
                          participant_id:
                            type: string
                            format: cuid
                            description: If the issuer is a signer or approver this is the ID of the related
                              participant.
                            example: cd0jga4zijaebyga1wlexample
                          signing_room_url:
                            nullable: true
                            type: string
                            format: url
                            example: https://www.zigned.se/sign/cjecfacxrxzqd9def5zexample/cmakdfl6yfb9ls8h6jyexample
                            description: The URL to the signing room for the issuer. Only available after
                              the agreement has been finalized for signing.
                          locale:
                            nullable: true
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                            description: The locale for the issuer. Can be overridden from the signing room,
                              but this value serves as the default if nothing
                              else is specified. If omitted, the default_locale
                              of the agreement is used.
                        required:
                          - name
                          - email
                          - role
                          - signing_room_url
                        description: The issuer of the agreement
                      participants:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the participants belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the participant resource.
                              resource_type:
                                type: string
                                enum:
                                  - participant
                                description: Data contains the participant resource.
                              data:
                                $ref: "#/components/schemas/95c1af3f45da65daeedb661f70210b46b2bd71d5"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      observers:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the observers belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the observer resource.
                              resource_type:
                                type: string
                                enum:
                                  - observer
                                description: Data contains the observer resource.
                              data:
                                $ref: "#/components/schemas/c893c5c1d97a5bcbd8972ce188f48f8f75c6a171"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      signing_groups:
                        oneOf:
                          - type: array
                            items:
                              type: string
                              format: cuid
                              minLength: 1
                            description: List of all IDs for the signing groups belonging to this agreement
                            example:
                              - c5lnvzb9saw7pkusnvcexample
                              - cgizx0nvpnyzxupx0cvexample
                              - codqlu3eiigxia664m3example
                          - type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - list
                                description: A non-paginated list of the signing group resource.
                              resource_type:
                                type: string
                                enum:
                                  - signing_group
                                description: Data contains the signing group resource.
                              data:
                                $ref: "#/components/schemas/d69cfbd1e408327b80080ee78c087563df3370f4"
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                          - type: string
                            nullable: true
                            format: "null"
                      documents:
                        type: object
                        properties:
                          original_documents:
                            type: object
                            properties:
                              main:
                                oneOf:
                                  - type: string
                                    format: cuid
                                    description: The unique identifier of the main document
                                    example: cmwqhs06osj0tus71kcexample
                                  - type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - single
                                        description: A single object of the file resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                        description: Data contains the file resource.
                                      data:
                                        type: object
                                        properties:
                                          id:
                                            type: string
                                            format: cuid
                                            description: The unique identifier of the file
                                            example: cytp5m6ijs4rxs0erqsexample
                                          resource_type:
                                            type: string
                                            enum:
                                              - file
                                          filename:
                                            type: string
                                            minLength: 1
                                            description: The complete filename including the file extension
                                            example: my-file.pdf
                                          mime_type:
                                            type: string
                                            minLength: 1
                                            description: The mime type of the file
                                            example: application/pdf
                                          url:
                                            type: string
                                            format: url
                                            description: The signed read url of the file
                                            example: https://zigned.se
                                          metadata:
                                            type: object
                                            properties:
                                              lookup_key:
                                                type: string
                                                description: A provided lookup key provided by you to help you identify the
                                                  file.
                                                example: file_tag
                                            required:
                                              - lookup_key
                                          created_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                          updated_at:
                                            type: string
                                            description: UTC datetime ISO string
                                            example: 2024-01-01T00:00:00.000Z
                                        required:
                                          - id
                                          - resource_type
                                          - filename
                                          - mime_type
                                          - created_at
                                          - updated_at
                                        description: The resource data.
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  - type: string
                                    nullable: true
                                    format: "null"
                                description: The main document which will be signed.
                              attachments:
                                oneOf:
                                  - type: array
                                    items:
                                      type: string
                                      format: cuid
                                      minLength: 1
                                    description: List of all IDs for the attachments belonging to this agreement
                                    example:
                                      - c5lnvzb9saw7pkusnvcexample
                                      - cgizx0nvpnyzxupx0cvexample
                                      - codqlu3eiigxia664m3example
                                  - type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the attachment resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - attachment
                                        description: Data contains the attachment resource.
                                      data:
                                        $ref: "#/components/schemas/18aea1f88c852890888d309ddd8605d8c0438d2b"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  - type: string
                                    nullable: true
                                    format: "null"
                            required:
                              - main
                          signed_document:
                            oneOf:
                              - type: string
                                format: cuid
                                description: The unique identifier for the signed document
                                example: ckfd2sygk12n9slxwkeexample
                              - type: object
                                properties:
                                  version:
                                    type: string
                                    enum:
                                      - "1.0"
                                    description: The version of the response schema
                                  result_type:
                                    type: string
                                    enum:
                                      - single
                                    description: A single object of the file resource.
                                  resource_type:
                                    type: string
                                    enum:
                                      - file
                                    description: Data contains the file resource.
                                  data:
                                    type: object
                                    properties:
                                      id:
                                        type: string
                                        format: cuid
                                        description: The unique identifier of the file
                                        example: cytp5m6ijs4rxs0erqsexample
                                      resource_type:
                                        type: string
                                        enum:
                                          - file
                                      filename:
                                        type: string
                                        minLength: 1
                                        description: The complete filename including the file extension
                                        example: my-file.pdf
                                      mime_type:
                                        type: string
                                        minLength: 1
                                        description: The mime type of the file
                                        example: application/pdf
                                      url:
                                        type: string
                                        format: url
                                        description: The signed read url of the file
                                        example: https://zigned.se
                                      metadata:
                                        type: object
                                        properties:
                                          lookup_key:
                                            type: string
                                            description: A provided lookup key provided by you to help you identify the
                                              file.
                                            example: file_tag
                                        required:
                                          - lookup_key
                                      created_at:
                                        type: string
                                        description: UTC datetime ISO string
                                        example: 2024-01-01T00:00:00.000Z
                                      updated_at:
                                        type: string
                                        description: UTC datetime ISO string
                                        example: 2024-01-01T00:00:00.000Z
                                    required:
                                      - id
                                      - resource_type
                                      - filename
                                      - mime_type
                                      - created_at
                                      - updated_at
                                    description: The resource data.
                                required:
                                  - version
                                  - result_type
                                  - resource_type
                                  - data
                              - type: string
                                nullable: true
                                format: "null"
                            description: The finalized and signed document.
                        required:
                          - original_documents
                          - signed_document
                      signing_order:
                        type: object
                        properties:
                          enabled:
                            type: boolean
                          grouped:
                            type: boolean
                        required:
                          - enabled
                          - grouped
                      communication:
                        type: object
                        properties:
                          send_emails:
                            type: boolean
                          default_locale:
                            nullable: true
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                            description: The default locale for the agreement. Can be overridden by
                              individual participants/observers from the signing
                              room, but this value serves as the default if
                              nothing else is specified.
                          automatic_reminders:
                            type: object
                            properties:
                              enabled:
                                type: boolean
                              intensity:
                                nullable: true
                                type: string
                                enum:
                                  - intense
                                  - normal
                                description: The intensity of the reminders. The reminders are scheduled with an
                                  exponential fall off, but the intensity
                                  regulates the base interval. If expiration
                                  date is set for the agreement, the reminders
                                  become more intense at the end.
                            required:
                              - enabled
                              - intensity
                          recipient_messages:
                            nullable: true
                            type: object
                            properties:
                              version:
                                type: string
                                enum:
                                  - "1.0"
                                description: The version of the response schema
                              result_type:
                                type: string
                                enum:
                                  - single
                                description: A single object of the recipient_message resource.
                              resource_type:
                                type: string
                                enum:
                                  - recipient_message
                                description: Data contains the recipient_message resource.
                              data:
                                type: object
                                properties:
                                  id:
                                    type: string
                                    format: cuid
                                    description: The unique identifier of the recipient message
                                    example: ck1ayqgg0fuxdetcvjtexample
                                  resource_type:
                                    type: string
                                    enum:
                                      - recipient_message
                                  message_templates:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the recipient message template resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - recipient_message_template
                                        description: Data contains the recipient message template resource.
                                      data:
                                        $ref: "#/components/schemas/7aadbd48657236af70d97541a9c85c00b14e95a5"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  message_template_variables:
                                    type: object
                                    properties:
                                      version:
                                        type: string
                                        enum:
                                          - "1.0"
                                        description: The version of the response schema
                                      result_type:
                                        type: string
                                        enum:
                                          - list
                                        description: A non-paginated list of the recipient message template variable
                                          resource.
                                      resource_type:
                                        type: string
                                        enum:
                                          - recipient_message_template_variable
                                        description: Data contains the recipient message template variable resource.
                                      data:
                                        $ref: "#/components/schemas/f9a847cbdf0e167d1aa8d3b7127afb96d878e823"
                                    required:
                                      - version
                                      - result_type
                                      - resource_type
                                      - data
                                  created_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                  updated_at:
                                    type: string
                                    description: UTC datetime ISO string
                                    example: 2024-01-01T00:00:00.000Z
                                required:
                                  - id
                                  - resource_type
                                  - message_templates
                                  - message_template_variables
                                  - created_at
                                  - updated_at
                                description: The resource data.
                            required:
                              - version
                              - result_type
                              - resource_type
                              - data
                        required:
                          - send_emails
                      metadata:
                        type: object
                        properties:
                          mask_pii:
                            type: boolean
                            default: true
                            description: Whether to mask PII visually on the signed document. Default is
                              true. Note that this only affects the visual
                              representation of the PII, the actual PII is still
                              present in the evidence package or certificate.
                          lookup_key:
                            type: string
                            description: A provided lookup key provided by you to help you identify the
                              agreement.
                            example: your_internal_customer_id
                          success_callback_url:
                            type: string
                            format: url
                            description: A provided callback url to refer the participants back to post
                              successful action.
                            example: https://yourdomain.com/sign-complete
                      expires_at:
                        nullable: true
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      delete_scheduled_at:
                        nullable: true
                        type: string
                        description: The timestamp when deletion is scheduled to occur. Null if not
                          scheduled.
                        example: 2024-01-01T00:00:00.000Z
                      deleted_at:
                        nullable: true
                        type: string
                        description: The timestamp when the agreement was deleted. Null if not deleted.
                        example: 2024-01-01T00:00:00.000Z
                      deleted:
                        type: boolean
                        description: Whether the agreement has been deleted. Returns true if either
                          scheduled for deletion or if already deleted.
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - test_mode
                      - status
                      - cancellation_reason
                      - theme
                      - issuer
                      - participants
                      - signing_order
                      - communication
                      - updated_at
                      - created_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: POST /agreements/:agreement_id/lifecycle Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: >-
        Update the lifecycle status of an agreement: `pending`, `open` or
        `cancelled`.


        **Pending**: When an agreement is switched to Pending, it is finalized
        for signing by validating all inputs and, if communication is enabled,
        sends out all or the first batch of invitations. A Pending agreement can
        be either cancelled or opened.


        **Open**: If the agreement is opened, the signing process is paused and
        reset to allow making any changes you would like to do.


        **Cancelled**: If you cancel the agreement, it is moved into an end
        state where no more changes are allowed. If communication is enabled and
        the agreement is cancelled, notifications will be sent to all
        participants.
      summary: Update Lifecycle State
      tags:
        - Agreements
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: POST /agreements/:agreement_id/lifecycle parameter
          schema:
            type: string
            format: cuid
            example: cqxeapqufadv8mnjfwwexample
      requestBody:
        description: POST /agreements/:agreement_id/lifecycle request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - type: object
                              properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                    - type: object
                      properties: {}
                      required: []
                - type: object
                  properties:
                    lifecycle_state:
                      discriminator:
                        propertyName: status
                      oneOf:
                        - type: object
                          properties:
                            status:
                              type: string
                              enum:
                                - cancelled
                            input:
                              discriminator:
                                propertyName: cancellation_type
                              oneOf:
                                - type: object
                                  properties:
                                    cancellation_type:
                                      type: string
                                      enum:
                                        - invalid_document
                                        - invalid_participant
                                        - invalid_email
                                  required:
                                    - cancellation_type
                                - type: object
                                  properties:
                                    cancellation_type:
                                      type: string
                                      enum:
                                        - custom
                                    reason:
                                      type: string
                                      minLength: 10
                                      maxLength: 255
                                  required:
                                    - cancellation_type
                                    - reason
                          required:
                            - status
                            - input
                        - type: object
                          properties:
                            status:
                              type: string
                              enum:
                                - open
                          required:
                            - status
                        - type: object
                          properties:
                            status:
                              type: string
                              enum:
                                - pending
                          required:
                            - status
                      description: The lifecycle state of the agreement
                  required:
                    - lifecycle_state
      security:
        - HTTP_1: []
  /agreements/{agreement_id}/reminders:
    post:
      operationId: PostAgreementsAgreementIdReminders
      responses:
        "200":
          description: POST /agreements/:agreement_id/reminders Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                  resource_type:
                    type: string
                    enum:
                      - reminder
                  result_type:
                    type: string
                    enum:
                      - list
                  data:
                    type: array
                    items:
                      type: object
                      properties:
                        status:
                          type: string
                        participant:
                          type: object
                          properties:
                            version:
                              type: string
                              enum:
                                - "1.0"
                              description: The version of the response schema
                            result_type:
                              type: string
                              enum:
                                - single
                              description: A single object of the participant resource.
                            resource_type:
                              type: string
                              enum:
                                - participant
                              description: Data contains the participant resource.
                            data:
                              allOf:
                                - type: object
                                  properties:
                                    id:
                                      type: string
                                      format: cuid
                                      description: The unique identifier of the participant
                                      example: c7uwzf2hygix6pmzsh5example
                                    resource_type:
                                      type: string
                                      enum:
                                        - participant
                                    name:
                                      nullable: true
                                      type: string
                                      description: The name of the participant. Required if no email is provided.
                                      example: Jane Doe
                                    email:
                                      nullable: true
                                      type: string
                                      description: The email of the participant. Required if agreemnt is configured to
                                        send emails.
                                      example: jane.doe@example.com
                                    status:
                                      type: string
                                      enum:
                                        - draft
                                        - pending
                                        - initiated
                                        - processing
                                        - fulfilled
                                        - rejected
                                      description: The status of the participant
                                    order:
                                      nullable: true
                                      type: number
                                      format: double
                                      minimum: 0
                                      exclusiveMinimum: true
                                      maximum: 1.7976931348623157e+308
                                      exclusiveMaximum: false
                                      description: The queue number of the participant (if sequential signing order is
                                        enabled)
                                      example: 1
                                    signing_group:
                                      oneOf:
                                        - type: string
                                          format: cuid
                                          description: The unique identifier for the signing groups
                                          example: cgbzlzelirbjrjq0xrxexample
                                        - $ref: "#/components/schemas/118cb3b11b8a1f3b6b1e60a89f96a8be9da32a0f"
                                        - type: string
                                          nullable: true
                                          format: "null"
                                    agreement:
                                      type: string
                                      format: cuid
                                      description: The unique identifier for the agreement this participant belongs to
                                      example: cj2orx6w6iqpscuqsieexample
                                    signing_room_url:
                                      nullable: true
                                      type: string
                                      format: url
                                      example: https://www.zigned.se/sign/cjecfacxrxzqd9def5zexample/cmakdfl6yfb9ls8h6jyexample
                                      description: The URL to the signing room for the participant. Only available
                                        after the agreement has been finalized
                                        for signing.
                                    locale:
                                      nullable: true
                                      type: string
                                      enum:
                                        - sv-SE
                                        - en-US
                                      description: The locale for the participant. Can be overridden from the signing
                                        room, but this value serves as the
                                        default if nothing else is specified.
                                    created_at:
                                      type: string
                                      description: UTC datetime ISO string
                                      example: 2024-01-01T00:00:00.000Z
                                    updated_at:
                                      type: string
                                      description: UTC datetime ISO string
                                      example: 2024-01-01T00:00:00.000Z
                                  required:
                                    - id
                                    - resource_type
                                    - name
                                    - email
                                    - status
                                    - order
                                    - signing_group
                                    - agreement
                                    - signing_room_url
                                    - created_at
                                    - updated_at
                                  description: The participant resource
                                - discriminator:
                                    propertyName: role
                                  oneOf:
                                    - type: object
                                      properties:
                                        role:
                                          type: string
                                          enum:
                                            - approver
                                          description: The role of the participant
                                        decision_made_at:
                                          nullable: true
                                          type: string
                                          description: UTC datetime ISO string
                                          example: 2024-01-01T00:00:00.000Z
                                      required:
                                        - role
                                        - decision_made_at
                                    - type: object
                                      properties:
                                        role:
                                          type: string
                                          enum:
                                            - signer
                                          description: The role of the participant
                                        signed_at:
                                          nullable: true
                                          type: string
                                          description: UTC datetime ISO string
                                          example: 2024-01-01T00:00:00.000Z
                                        signature:
                                          nullable: true
                                          oneOf:
                                            - allOf:
                                                - type: object
                                                  properties:
                                                    id:
                                                      type: string
                                                      format: cuid
                                                      description: The unique identifier of the signature data
                                                      example: cqdax9rdsuqyvtgemlzexample
                                                    created_at:
                                                      type: string
                                                      description: UTC datetime ISO string
                                                      example: 2024-01-01T00:00:00.000Z
                                                    updated_at:
                                                      type: string
                                                      description: UTC datetime ISO string
                                                      example: 2024-01-01T00:00:00.000Z
                                                  required:
                                                    - id
                                                    - created_at
                                                    - updated_at
                                                - discriminator:
                                                    propertyName: method
                                                  oneOf:
                                                    - type: object
                                                      properties:
                                                        method:
                                                          type: string
                                                          enum:
                                                            - se_bid
                                                          description: The method used for signing
                                                        data:
                                                          type: object
                                                          properties:
                                                            name:
                                                              nullable: true
                                                              type: string
                                                              description: The full name of the signer returned by Mobile Swedish BankID
                                                              example: Jane Doe
                                                            user_message:
                                                              type: string
                                                              description: The message presented to the user in the Mobile BankID application
                                                                when signing
                                                              example: I have read and understood the contents of the document example.pdf and
                                                                I hereby approve
                                                                everything in it.
                                                            document_hash:
                                                              type: string
                                                              description: The SHA256 hash of the document to be signed (Base64 encoded)
                                                              example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                            status:
                                                              type: string
                                                              enum:
                                                                - complete
                                                                - error
                                                                - failed
                                                                - draft
                                                                - pending
                                                                - initializing
                                                                - cancelled
                                                              description: The status for the Swedish BankID signing process
                                                          required:
                                                            - name
                                                            - user_message
                                                            - document_hash
                                                            - status
                                                          description: Summary of the BankID signature data
                                                      required:
                                                        - method
                                                        - data
                                                    - type: object
                                                      properties:
                                                        method:
                                                          type: string
                                                          enum:
                                                            - verification_code
                                                          description: The method used for signing
                                                        data:
                                                          type: object
                                                          properties:
                                                            email:
                                                              nullable: true
                                                              type: string
                                                              description: The email used for the verification code
                                                              example: john.doe@example.com
                                                            name:
                                                              nullable: true
                                                              type: string
                                                              description: The name of the signer
                                                              example: John Doe
                                                            user_message:
                                                              type: string
                                                              description: The message presented to the user when signing
                                                              example: I have read and understood the contents of the document example.pdf and
                                                                I hereby approve
                                                                everything in it.
                                                            document_hash:
                                                              type: string
                                                              description: The SHA256 hash of the document to be signed (Base64 encoded)
                                                              example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                            status:
                                                              type: string
                                                              enum:
                                                                - confirmed
                                                                - draft
                                                                - pending
                                                                - confirmation_failed
                                                                - unable_to_send
                                                                - expired
                                                                - cancelled
                                                              description: The status of the verification code signing process
                                                          required:
                                                            - email
                                                            - name
                                                            - user_message
                                                            - document_hash
                                                            - status
                                                          description: Summary of the verification code signature data
                                                      required:
                                                        - method
                                                        - data
                                                    - type: object
                                                      properties:
                                                        method:
                                                          type: string
                                                          enum:
                                                            - truid
                                                          description: The method used for signing
                                                        data:
                                                          type: object
                                                          properties:
                                                            given_name:
                                                              nullable: true
                                                              type: string
                                                              description: The given name of the signer returned by Truid
                                                              example: Jane
                                                            family_name:
                                                              nullable: true
                                                              type: string
                                                              description: The family name of the signer returned by Truid
                                                              example: Doe
                                                            legal_name:
                                                              nullable: true
                                                              type: string
                                                              description: The legal name of the signer returned by Truid
                                                              example: Jane Doe
                                                            user_message:
                                                              type: string
                                                              description: The message presented to the user in the Truid application when
                                                                signing
                                                              example: I have read and wish to sign the document.
                                                            document_hash:
                                                              type: string
                                                              description: The SHA256 hash of the document to be signed (Base64 encoded)
                                                              example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                            status:
                                                              type: string
                                                              enum:
                                                                - draft
                                                                - pending
                                                                - fulfilled
                                                                - failed
                                                              description: The status for the Truid signing process
                                                          required:
                                                            - given_name
                                                            - family_name
                                                            - legal_name
                                                            - user_message
                                                            - document_hash
                                                            - status
                                                          description: Summary of the Truid signature data
                                                      required:
                                                        - method
                                                        - data
                                                    - type: object
                                                      properties:
                                                        method:
                                                          type: string
                                                          enum:
                                                            - zealid
                                                          description: The method used for signing
                                                        data:
                                                          type: object
                                                          properties:
                                                            givenname:
                                                              nullable: true
                                                              type: string
                                                              description: The given name of the signer as specified in the signing
                                                                certificate
                                                              example: Jane
                                                            surname:
                                                              nullable: true
                                                              type: string
                                                              description: The surname of the signer as specified in the signing certificate
                                                              example: Doe
                                                            country:
                                                              nullable: true
                                                              type: string
                                                              description: The country of the signer as specified in the signing certificate
                                                              example: SE
                                                            identifier:
                                                              nullable: true
                                                              type: string
                                                              description: The primary identifier, such as a Swedish Personal Number, as
                                                                specified in the
                                                                signing certificate
                                                              example: SE
                                                            signing_certificate:
                                                              nullable: true
                                                              type: string
                                                              description: The signing certificate for the signatory, returned by ZealID
                                                              example: >-
                                                                
                                                                --BEGIN
                                                                CERTIFICATE--

                                                                [BASE64 ENCODED
                                                                CERTIFICATE]

                                                                --END CERTIFICATE--
                                                            document_hash:
                                                              type: string
                                                              description: The SHA256 hash of the data to be signed (Base64 encoded)
                                                              example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                                            status:
                                                              type: string
                                                              enum:
                                                                - draft
                                                                - awaiting_authentication
                                                                - awaiting_sign
                                                                - complete
                                                                - failed
                                                              description: The status for the ZealID signing process
                                                          required:
                                                            - givenname
                                                            - surname
                                                            - country
                                                            - identifier
                                                            - signing_certificate
                                                            - document_hash
                                                            - status
                                                          description: Summary of the ZealID signature data
                                                      required:
                                                        - method
                                                        - data
                                            - type: object
                                              properties:
                                                method:
                                                  type: string
                                                  nullable: true
                                                  format: "null"
                                                data:
                                                  type: string
                                                  nullable: true
                                                  format: "null"
                                              required:
                                                - method
                                                - data
                                          description: The signature data for the participant
                                        identity_enforcement:
                                          discriminator:
                                            propertyName: enabled
                                          oneOf:
                                            - type: object
                                              properties:
                                                enabled:
                                                  type: boolean
                                                  enum:
                                                    - true
                                                  description: If true, identity enforcement is enabled for the participant
                                                status:
                                                  type: string
                                                  enum:
                                                    - pending
                                                    - passed
                                                    - failed
                                                  description: The status of the identity enforcement
                                                enforcement_method:
                                                  type: string
                                                  enum:
                                                    - swe_pno_crosscheck
                                                  description: The enforcement method for the identity. Depending on which method
                                                    is used, different signature
                                                    method are available
                                              required:
                                                - enabled
                                                - status
                                                - enforcement_method
                                            - type: object
                                              properties:
                                                enabled:
                                                  type: boolean
                                                  enum:
                                                    - false
                                                  description: If true, identity enforcement is enabled for the participant
                                                status:
                                                  type: string
                                                  nullable: true
                                                  format: "null"
                                                enforcement_method:
                                                  type: string
                                                  nullable: true
                                                  format: "null"
                                              required:
                                                - enabled
                                                - status
                                                - enforcement_method
                                      required:
                                        - role
                                        - signed_at
                                        - signature
                                        - identity_enforcement
                              description: The resource data.
                          required:
                            - version
                            - result_type
                            - resource_type
                            - data
                      required:
                        - status
                        - participant
                required:
                  - version
                  - resource_type
                  - result_type
                  - data
        "400":
          description: POST /agreements/:agreement_id/reminders Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Send a reminder to participants within an agreement
      summary: Send Reminders
      tags:
        - Agreements
        - Reminders
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: POST /agreements/:agreement_id/reminders parameter
          schema:
            type: string
            format: cuid
            example: cvlis58ncgsty23eqvvexample
      requestBody:
        description: POST /agreements/:agreement_id/reminders request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - type: object
                              properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                    - type: object
                      properties: {}
                      required: []
                - type: object
                  properties:
                    participant_id:
                      type: string
                      format: cuid
                      example: cey34elffev2hcwl39uexample
                  required: []
      security:
        - HTTP_1: []
  /agreements/{agreement_id}/recipient_messages:
    post:
      operationId: PostAgreementsAgreementIdRecipientMessages
      responses:
        "200":
          description: POST /agreements/:agreement_id/recipient_messages Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the recipient_message resource.
                  resource_type:
                    type: string
                    enum:
                      - recipient_message
                    description: Data contains the recipient_message resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the recipient message
                        example: ck1ayqgg0fuxdetcvjtexample
                      resource_type:
                        type: string
                        enum:
                          - recipient_message
                      message_templates:
                        type: object
                        properties:
                          version:
                            type: string
                            enum:
                              - "1.0"
                            description: The version of the response schema
                          result_type:
                            type: string
                            enum:
                              - list
                            description: A non-paginated list of the recipient message template resource.
                          resource_type:
                            type: string
                            enum:
                              - recipient_message_template
                            description: Data contains the recipient message template resource.
                          data:
                            $ref: "#/components/schemas/7aadbd48657236af70d97541a9c85c00b14e95a5"
                        required:
                          - version
                          - result_type
                          - resource_type
                          - data
                      message_template_variables:
                        type: object
                        properties:
                          version:
                            type: string
                            enum:
                              - "1.0"
                            description: The version of the response schema
                          result_type:
                            type: string
                            enum:
                              - list
                            description: A non-paginated list of the recipient message template variable
                              resource.
                          resource_type:
                            type: string
                            enum:
                              - recipient_message_template_variable
                            description: Data contains the recipient message template variable resource.
                          data:
                            $ref: "#/components/schemas/f9a847cbdf0e167d1aa8d3b7127afb96d878e823"
                        required:
                          - version
                          - result_type
                          - resource_type
                          - data
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - message_templates
                      - message_template_variables
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: POST /agreements/:agreement_id/recipient_messages Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Upsert a new recipient message. Use the Recipient Message ID in
        subsequent requests.
      summary: Upsert a Recipient Message
      tags: &a2
        - Agreements
        - Recipient Message
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: POST /agreements/:agreement_id/recipient_messages parameter
          schema:
            type: string
            format: cuid
            example: cylyh7psg1vq51c3h6uexample
      requestBody:
        description: POST /agreements/:agreement_id/recipient_messages request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - allOf:
                                - type: object
                                  properties: {}
                                - type: object
                                  properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                          required: []
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    message_templates:
                      type: array
                      items:
                        type: object
                        properties:
                          locale:
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                          template_string:
                            type: string
                            description: The message template string. Supports simple markdown and dynamic
                              data variables via mustache syntax.
                            example: "**Hey there {{recipient.name}}**! Please sign {{agreement.filename}}
                              by clicking the link below."
                        required:
                          - locale
                          - template_string
                    message_template_variables:
                      type: array
                      items:
                        type: object
                        properties:
                          variable_name:
                            type: string
                            description: The name of the variable. Supports dot notation such as
                              "my.variable.name". All values will be escaped and
                              sanitized so refrain from uncommon characters or
                              HTML.
                            example: my_variable_name
                          variable_value:
                            type: string
                            description: The variable value. Must be provided as a string, but booleans and
                              numbers will be parsed to their native types. Any
                              HTML will be escaped.
                            example: my_variable_name
                        required:
                          - variable_name
                          - variable_value
                      default: &a3 []
                  required:
                    - message_templates
      security:
        - HTTP_1: []
    put:
      operationId: PutAgreementsAgreementIdRecipientMessages
      responses:
        "200":
          description: PUT /agreements/:agreement_id/recipient_messages Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the recipient_message resource.
                  resource_type:
                    type: string
                    enum:
                      - recipient_message
                    description: Data contains the recipient_message resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the recipient message
                        example: ck1ayqgg0fuxdetcvjtexample
                      resource_type:
                        type: string
                        enum:
                          - recipient_message
                      message_templates:
                        type: object
                        properties:
                          version:
                            type: string
                            enum:
                              - "1.0"
                            description: The version of the response schema
                          result_type:
                            type: string
                            enum:
                              - list
                            description: A non-paginated list of the recipient message template resource.
                          resource_type:
                            type: string
                            enum:
                              - recipient_message_template
                            description: Data contains the recipient message template resource.
                          data:
                            $ref: "#/components/schemas/7aadbd48657236af70d97541a9c85c00b14e95a5"
                        required:
                          - version
                          - result_type
                          - resource_type
                          - data
                      message_template_variables:
                        type: object
                        properties:
                          version:
                            type: string
                            enum:
                              - "1.0"
                            description: The version of the response schema
                          result_type:
                            type: string
                            enum:
                              - list
                            description: A non-paginated list of the recipient message template variable
                              resource.
                          resource_type:
                            type: string
                            enum:
                              - recipient_message_template_variable
                            description: Data contains the recipient message template variable resource.
                          data:
                            $ref: "#/components/schemas/f9a847cbdf0e167d1aa8d3b7127afb96d878e823"
                        required:
                          - version
                          - result_type
                          - resource_type
                          - data
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - message_templates
                      - message_template_variables
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: PUT /agreements/:agreement_id/recipient_messages Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Upsert a new recipient message. Use the Recipient Message ID in
        subsequent requests.
      summary: Upsert a Recipient Message
      tags: *a2
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: PUT /agreements/:agreement_id/recipient_messages parameter
          schema:
            type: string
            format: cuid
            example: cylyh7psg1vq51c3h6uexample
      requestBody:
        description: PUT /agreements/:agreement_id/recipient_messages request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - allOf:
                                - type: object
                                  properties: {}
                                - type: object
                                  properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                          required: []
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    message_templates:
                      type: array
                      items:
                        type: object
                        properties:
                          locale:
                            type: string
                            enum:
                              - sv-SE
                              - en-US
                          template_string:
                            type: string
                            description: The message template string. Supports simple markdown and dynamic
                              data variables via mustache syntax.
                            example: "**Hey there {{recipient.name}}**! Please sign {{agreement.filename}}
                              by clicking the link below."
                        required:
                          - locale
                          - template_string
                    message_template_variables:
                      type: array
                      items:
                        type: object
                        properties:
                          variable_name:
                            type: string
                            description: The name of the variable. Supports dot notation such as
                              "my.variable.name". All values will be escaped and
                              sanitized so refrain from uncommon characters or
                              HTML.
                            example: my_variable_name
                          variable_value:
                            type: string
                            description: The variable value. Must be provided as a string, but booleans and
                              numbers will be parsed to their native types. Any
                              HTML will be escaped.
                            example: my_variable_name
                        required:
                          - variable_name
                          - variable_value
                      default: *a3
                  required:
                    - message_templates
      security:
        - HTTP_1: []
    get:
      operationId: GetAgreementsAgreementIdRecipientMessages
      responses:
        "200":
          description: GET /agreements/:agreement_id/recipient_messages Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the recipient_message resource.
                  resource_type:
                    type: string
                    enum:
                      - recipient_message
                    description: Data contains the recipient_message resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the recipient message
                        example: ck1ayqgg0fuxdetcvjtexample
                      resource_type:
                        type: string
                        enum:
                          - recipient_message
                      message_templates:
                        type: object
                        properties:
                          version:
                            type: string
                            enum:
                              - "1.0"
                            description: The version of the response schema
                          result_type:
                            type: string
                            enum:
                              - list
                            description: A non-paginated list of the recipient message template resource.
                          resource_type:
                            type: string
                            enum:
                              - recipient_message_template
                            description: Data contains the recipient message template resource.
                          data:
                            $ref: "#/components/schemas/7aadbd48657236af70d97541a9c85c00b14e95a5"
                        required:
                          - version
                          - result_type
                          - resource_type
                          - data
                      message_template_variables:
                        type: object
                        properties:
                          version:
                            type: string
                            enum:
                              - "1.0"
                            description: The version of the response schema
                          result_type:
                            type: string
                            enum:
                              - list
                            description: A non-paginated list of the recipient message template variable
                              resource.
                          resource_type:
                            type: string
                            enum:
                              - recipient_message_template_variable
                            description: Data contains the recipient message template variable resource.
                          data:
                            $ref: "#/components/schemas/f9a847cbdf0e167d1aa8d3b7127afb96d878e823"
                        required:
                          - version
                          - result_type
                          - resource_type
                          - data
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - message_templates
                      - message_template_variables
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: GET /agreements/:agreement_id/recipient_messages Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Lists all recipient messages for the agreement.
      summary: List Recipient Messages
      tags:
        - Agreements
        - Recipient Message
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: GET /agreements/:agreement_id/recipient_messages parameter
          schema:
            type: string
            format: cuid
            example: cje6b8gn7qbctyyr4zkexample
      security:
        - HTTP_1: []
    delete:
      operationId: DeleteAgreementsAgreementIdRecipientMessages
      responses:
        "200":
          description: DELETE /agreements/:agreement_id/recipient_messages Successful
            response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - deleted
                    description: Returns a single object of the recipient_message resource which was
                      deleted.
                  resource_type:
                    type: string
                    enum:
                      - recipient_message
                    description: Data contains the recipient_message resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the recipient message
                        example: ck1ayqgg0fuxdetcvjtexample
                      resource_type:
                        type: string
                        enum:
                          - recipient_message
                      message_templates:
                        type: object
                        properties:
                          version:
                            type: string
                            enum:
                              - "1.0"
                            description: The version of the response schema
                          result_type:
                            type: string
                            enum:
                              - list
                            description: A non-paginated list of the recipient message template resource.
                          resource_type:
                            type: string
                            enum:
                              - recipient_message_template
                            description: Data contains the recipient message template resource.
                          data:
                            $ref: "#/components/schemas/7aadbd48657236af70d97541a9c85c00b14e95a5"
                        required:
                          - version
                          - result_type
                          - resource_type
                          - data
                      message_template_variables:
                        type: object
                        properties:
                          version:
                            type: string
                            enum:
                              - "1.0"
                            description: The version of the response schema
                          result_type:
                            type: string
                            enum:
                              - list
                            description: A non-paginated list of the recipient message template variable
                              resource.
                          resource_type:
                            type: string
                            enum:
                              - recipient_message_template_variable
                            description: Data contains the recipient message template variable resource.
                          data:
                            $ref: "#/components/schemas/f9a847cbdf0e167d1aa8d3b7127afb96d878e823"
                        required:
                          - version
                          - result_type
                          - resource_type
                          - data
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - message_templates
                      - message_template_variables
                      - created_at
                      - updated_at
                    description: The resource data that was deleted.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: DELETE /agreements/:agreement_id/recipient_messages Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Deletes all recipient messages for the agreement. Keep in mind, if
        the template is saved in your archive, it will NOT be removed from
        there, only from the agreement.
      summary: Delete Recipient Messages
      tags:
        - Agreements
        - Recipient Message
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: DELETE /agreements/:agreement_id/recipient_messages parameter
          schema:
            type: string
            format: cuid
            example: c1vqtmundxau1zfljhdexample
      security:
        - HTTP_1: []
  /agreements/{agreement_id}/recipient_messages/message_templates:
    get:
      operationId: GetAgreementsAgreementIdRecipientMessagesMessageTemplates
      responses:
        "200":
          description: GET /agreements/:agreement_id/recipient_messages/message_templates
            Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - list
                    description: A non-paginated list of the recipient message template resource.
                  resource_type:
                    type: string
                    enum:
                      - recipient_message_template
                    description: Data contains the recipient message template resource.
                  data:
                    $ref: "#/components/schemas/7aadbd48657236af70d97541a9c85c00b14e95a5"
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: GET /agreements/:agreement_id/recipient_messages/message_templates
            Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Lists all message templates for the agreement
      summary: List Message Templates
      tags:
        - Agreements
        - Recipient Message
        - Message Template
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: GET /agreements/:agreement_id/recipient_messages/message_templates
            parameter
          schema:
            type: string
            format: cuid
            example: cdovr6sbo8kclb5rx6bexample
      security:
        - HTTP_1: []
    post:
      operationId: PostAgreementsAgreementIdRecipientMessagesMessageTemplates
      responses:
        "200":
          description: POST /agreements/:agreement_id/recipient_messages/message_templates
            Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the recipient_message_template resource.
                  resource_type:
                    type: string
                    enum:
                      - recipient_message_template
                    description: Data contains the recipient_message_template resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the recipient message template
                        example: cbffwj3f8wjic8dnnnyexample
                      template_string:
                        type: string
                      resource_type:
                        type: string
                        enum:
                          - recipient_message_template
                      locale:
                        type: string
                        enum:
                          - sv-SE
                          - en-US
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - template_string
                      - resource_type
                      - locale
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: POST /agreements/:agreement_id/recipient_messages/message_templates
            Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Create a message template.
      summary: Create a Message Template
      tags:
        - Agreements
        - Recipient Message
        - Message Template
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: POST /agreements/:agreement_id/recipient_messages/message_templates
            parameter
          schema:
            type: string
            format: cuid
            example: ctthbaafrsgttzjhmgbexample
      requestBody:
        description: POST /agreements/:agreement_id/recipient_messages/message_templates
          request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - allOf:
                                - type: object
                                  properties: {}
                                - type: object
                                  properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                          required: []
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    locale:
                      type: string
                      enum:
                        - sv-SE
                        - en-US
                    template_string:
                      type: string
                      description: The message template string. Supports simple markdown and dynamic
                        data variables via mustache syntax.
                      example: "**Hey there {{recipient.name}}**! Please sign {{agreement.filename}}
                        by clicking the link below."
                  required:
                    - locale
                    - template_string
      security:
        - HTTP_1: []
  /agreements/{agreement_id}/recipient_messages/message_templates/{message_template_id}:
    get:
      operationId: GetAgreementsAgreementIdRecipientMessagesMessageTemplatesMessageTemplateId
      responses:
        "200":
          description: GET
            /agreements/:agreement_id/recipient_messages/message_templates/:message_template_id
            Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the recipient_message_template resource.
                  resource_type:
                    type: string
                    enum:
                      - recipient_message_template
                    description: Data contains the recipient_message_template resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the recipient message template
                        example: cbffwj3f8wjic8dnnnyexample
                      template_string:
                        type: string
                      resource_type:
                        type: string
                        enum:
                          - recipient_message_template
                      locale:
                        type: string
                        enum:
                          - sv-SE
                          - en-US
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - template_string
                      - resource_type
                      - locale
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: GET
            /agreements/:agreement_id/recipient_messages/message_templates/:message_template_id
            Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Retrieves a single message template for an agreement
      summary: Retrieve a Message Template
      tags:
        - Agreements
        - Recipient Message
        - Message Template
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: GET
            /agreements/:agreement_id/recipient_messages/message_templates/:message_template_id
            parameter
          schema:
            type: string
            format: cuid
            example: cmiov9zi07guao8vjsfexample
        - name: message_template_id
          in: path
          required: true
          description: GET
            /agreements/:agreement_id/recipient_messages/message_templates/:message_template_id
            parameter
          schema:
            type: string
            format: cuid
            example: cmn7khqxtcme8j1hvumexample
      security:
        - HTTP_1: []
    put:
      operationId: PutAgreementsAgreementIdRecipientMessagesMessageTemplatesMessageTemplateId
      responses:
        "200":
          description: PUT
            /agreements/:agreement_id/recipient_messages/message_templates/:message_template_id
            Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the recipient_message_template resource.
                  resource_type:
                    type: string
                    enum:
                      - recipient_message_template
                    description: Data contains the recipient_message_template resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the recipient message template
                        example: cbffwj3f8wjic8dnnnyexample
                      template_string:
                        type: string
                      resource_type:
                        type: string
                        enum:
                          - recipient_message_template
                      locale:
                        type: string
                        enum:
                          - sv-SE
                          - en-US
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - template_string
                      - resource_type
                      - locale
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: PUT
            /agreements/:agreement_id/recipient_messages/message_templates/:message_template_id
            Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Update a recipient message template.
      summary: Update a Message Template
      tags:
        - Agreements
        - Recipient Message
        - Message Template
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: PUT
            /agreements/:agreement_id/recipient_messages/message_templates/:message_template_id
            parameter
          schema:
            type: string
            format: cuid
            example: cw3zehyixctiewlgi1zexample
        - name: message_template_id
          in: path
          required: true
          description: PUT
            /agreements/:agreement_id/recipient_messages/message_templates/:message_template_id
            parameter
          schema:
            type: string
            format: cuid
            example: cm2l6ybanu4troonpcyexample
      requestBody:
        description: PUT
          /agreements/:agreement_id/recipient_messages/message_templates/:message_template_id
          request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - allOf:
                                - type: object
                                  properties: {}
                                - type: object
                                  properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                          required: []
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    template_string:
                      type: string
                      description: The message template string. Supports simple markdown and dynamic
                        data variables via mustache syntax.
                      example: "**Hey there {{recipient.name}}**! Please sign {{agreement.filename}}
                        by clicking the link below."
                  required:
                    - template_string
      security:
        - HTTP_1: []
    delete:
      operationId: DeleteAgreementsAgreementIdRecipientMessagesMessageTemplatesMessageTemplateId
      responses:
        "200":
          description: DELETE
            /agreements/:agreement_id/recipient_messages/message_templates/:message_template_id
            Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - deleted
                    description: Returns a single object of the recipient_message_template resource
                      which was deleted.
                  resource_type:
                    type: string
                    enum:
                      - recipient_message_template
                    description: Data contains the recipient_message_template resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the recipient message template
                        example: cbffwj3f8wjic8dnnnyexample
                      template_string:
                        type: string
                      resource_type:
                        type: string
                        enum:
                          - recipient_message_template
                      locale:
                        type: string
                        enum:
                          - sv-SE
                          - en-US
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - template_string
                      - resource_type
                      - locale
                      - created_at
                      - updated_at
                    description: The resource data that was deleted.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: DELETE
            /agreements/:agreement_id/recipient_messages/message_templates/:message_template_id
            Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Delete a recipient message template.
      summary: Delete a Message Template
      tags:
        - Agreements
        - Recipient Message
        - Message Template
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: DELETE
            /agreements/:agreement_id/recipient_messages/message_templates/:message_template_id
            parameter
          schema:
            type: string
            format: cuid
            example: crmyisof5k4wlp6trb4example
        - name: message_template_id
          in: path
          required: true
          description: DELETE
            /agreements/:agreement_id/recipient_messages/message_templates/:message_template_id
            parameter
          schema:
            type: string
            format: cuid
            example: cjqmrut0kvs0w7zyk8mexample
      security:
        - HTTP_1: []
  /agreements/{agreement_id}/recipient_messages/message_template_variables:
    get:
      operationId: GetAgreementsAgreementIdRecipientMessagesMessageTemplateVariables
      responses:
        "200":
          description: GET
            /agreements/:agreement_id/recipient_messages/message_template_variables
            Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - list
                    description: A non-paginated list of the recipient message template variable
                      resource.
                  resource_type:
                    type: string
                    enum:
                      - recipient_message_template_variable
                    description: Data contains the recipient message template variable resource.
                  data:
                    $ref: "#/components/schemas/f9a847cbdf0e167d1aa8d3b7127afb96d878e823"
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: GET
            /agreements/:agreement_id/recipient_messages/message_template_variables
            Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Lists all message template variable defined for the recipient message.
      summary: List Template Variables
      tags:
        - Agreements
        - Recipient Message
        - Template Variable
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: GET
            /agreements/:agreement_id/recipient_messages/message_template_variables
            parameter
          schema:
            type: string
            format: cuid
            example: cumvr68jeuoxounqp3bexample
      security:
        - HTTP_1: []
    post:
      operationId: PostAgreementsAgreementIdRecipientMessagesMessageTemplateVariables
      responses:
        "200":
          description: POST
            /agreements/:agreement_id/recipient_messages/message_template_variables
            Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the recipient_message_template_variable
                      resource.
                  resource_type:
                    type: string
                    enum:
                      - recipient_message_template_variable
                    description: Data contains the recipient_message_template_variable resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the recipient message variable
                        example: cbm5u2qzzrdgnx6b3tzexample
                      resource_type:
                        type: string
                        enum:
                          - recipient_message_template_variable
                      variable_name:
                        type: string
                      variable_value:
                        type: string
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - variable_name
                      - variable_value
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: POST
            /agreements/:agreement_id/recipient_messages/message_template_variables
            Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Create a message template variable for the agreement.
      summary: Create a Template Variable
      tags:
        - Agreements
        - Recipient Message
        - Template Variable
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: POST
            /agreements/:agreement_id/recipient_messages/message_template_variables
            parameter
          schema:
            type: string
            format: cuid
            example: c3vkukcsqgjeasifpwlexample
      requestBody:
        description: POST
          /agreements/:agreement_id/recipient_messages/message_template_variables
          request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - allOf:
                                - type: object
                                  properties: {}
                                - type: object
                                  properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                          required: []
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    variable_value:
                      type: string
                      description: The value of the variable. Booleans and numbers must be passed as
                        string, but will be parsed into their native types when
                        used. All values will be sanitized.
                      example: bar
                    variable_name:
                      type: string
                      description: The name of the variable. All values will be sanitized.
                      example: foo
                  required:
                    - variable_value
                    - variable_name
      security:
        - HTTP_1: []
  /agreements/{agreement_id}/recipient_messages/message_template_variables/{message_template_variable_id}:
    get:
      operationId: GetAgreementsAgreementIdRecipientMessagesMessageTemplateVariablesMessageTemplateVariableId
      responses:
        "200":
          description: GET
            /agreements/:agreement_id/recipient_messages/message_template_variables/:message_template_variable_id
            Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the recipient_message_template_variable
                      resource.
                  resource_type:
                    type: string
                    enum:
                      - recipient_message_template_variable
                    description: Data contains the recipient_message_template_variable resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the recipient message variable
                        example: cbm5u2qzzrdgnx6b3tzexample
                      resource_type:
                        type: string
                        enum:
                          - recipient_message_template_variable
                      variable_name:
                        type: string
                      variable_value:
                        type: string
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - variable_name
                      - variable_value
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: GET
            /agreements/:agreement_id/recipient_messages/message_template_variables/:message_template_variable_id
            Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Retrieves a single recipient message template variable.
      summary: Retrieve a Template Variable
      tags:
        - Agreements
        - Recipient Message
        - Template Variable
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: GET
            /agreements/:agreement_id/recipient_messages/message_template_variables/:message_template_variable_id
            parameter
          schema:
            type: string
            format: cuid
            example: c80we5zyaq1respcj9dexample
        - name: message_template_variable_id
          in: path
          required: true
          description: GET
            /agreements/:agreement_id/recipient_messages/message_template_variables/:message_template_variable_id
            parameter
          schema:
            type: string
            format: cuid
            example: cdgmh1bi6q6accirbmcexample
      security:
        - HTTP_1: []
    put:
      operationId: PutAgreementsAgreementIdRecipientMessagesMessageTemplateVariablesMessageTemplateVariableId
      responses:
        "200":
          description: PUT
            /agreements/:agreement_id/recipient_messages/message_template_variables/:message_template_variable_id
            Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the recipient_message_template_variable
                      resource.
                  resource_type:
                    type: string
                    enum:
                      - recipient_message_template_variable
                    description: Data contains the recipient_message_template_variable resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the recipient message variable
                        example: cbm5u2qzzrdgnx6b3tzexample
                      resource_type:
                        type: string
                        enum:
                          - recipient_message_template_variable
                      variable_name:
                        type: string
                      variable_value:
                        type: string
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - variable_name
                      - variable_value
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: PUT
            /agreements/:agreement_id/recipient_messages/message_template_variables/:message_template_variable_id
            Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Update a template variable.
      summary: Update a Template Variable
      tags:
        - Agreements
        - Recipient Message
        - Template Variable
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: PUT
            /agreements/:agreement_id/recipient_messages/message_template_variables/:message_template_variable_id
            parameter
          schema:
            type: string
            format: cuid
            example: cs3j4ydxcovulfwdiliexample
        - name: message_template_variable_id
          in: path
          required: true
          description: PUT
            /agreements/:agreement_id/recipient_messages/message_template_variables/:message_template_variable_id
            parameter
          schema:
            type: string
            format: cuid
            example: c3ibsuz99qmyeejb6ydexample
      requestBody:
        description: PUT
          /agreements/:agreement_id/recipient_messages/message_template_variables/:message_template_variable_id
          request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - allOf:
                                - type: object
                                  properties: {}
                                - type: object
                                  properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                          required: []
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    variable_value:
                      type: string
                      description: The value of the variable. Booleans and numbers must be passed as
                        string, but will be parsed into their native types when
                        used. All values will be sanitized.
                      example: bar
                    variable_name:
                      type: string
                      description: The name of the variable. All values will be sanitized.
                      example: foo
                  required: []
      security:
        - HTTP_1: []
    delete:
      operationId: DeleteAgreementsAgreementIdRecipientMessagesMessageTemplateVariablesMessageTemplateVariableId
      responses:
        "200":
          description: DELETE
            /agreements/:agreement_id/recipient_messages/message_template_variables/:message_template_variable_id
            Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - deleted
                    description: Returns a single object of the recipient_message_template_variable
                      resource which was deleted.
                  resource_type:
                    type: string
                    enum:
                      - recipient_message_template_variable
                    description: Data contains the recipient_message_template_variable resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the recipient message variable
                        example: cbm5u2qzzrdgnx6b3tzexample
                      resource_type:
                        type: string
                        enum:
                          - recipient_message_template_variable
                      variable_name:
                        type: string
                      variable_value:
                        type: string
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - variable_name
                      - variable_value
                      - created_at
                      - updated_at
                    description: The resource data that was deleted.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: DELETE
            /agreements/:agreement_id/recipient_messages/message_template_variables/:message_template_variable_id
            Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Delete a message template variable.
      summary: Delete a Template Variable
      tags:
        - Agreements
        - Recipient Message
        - Template Variable
      parameters:
        - name: agreement_id
          in: path
          required: true
          description: DELETE
            /agreements/:agreement_id/recipient_messages/message_template_variables/:message_template_variable_id
            parameter
          schema:
            type: string
            format: cuid
            example: c1yfhtpnxudbaallh4rexample
        - name: message_template_variable_id
          in: path
          required: true
          description: DELETE
            /agreements/:agreement_id/recipient_messages/message_template_variables/:message_template_variable_id
            parameter
          schema:
            type: string
            format: cuid
            example: cu8teq4htnkjloafy5zexample
      security:
        - HTTP_1: []
  /files:
    post:
      operationId: PostFiles
      responses:
        "200":
          description: POST /files Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the file resource.
                  resource_type:
                    type: string
                    enum:
                      - file
                    description: Data contains the file resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the file
                        example: cytp5m6ijs4rxs0erqsexample
                      resource_type:
                        type: string
                        enum:
                          - file
                      filename:
                        type: string
                        minLength: 1
                        description: The complete filename including the file extension
                        example: my-file.pdf
                      mime_type:
                        type: string
                        minLength: 1
                        description: The mime type of the file
                        example: application/pdf
                      url:
                        type: string
                        format: url
                        description: The signed read url of the file
                        example: https://zigned.se
                      metadata:
                        type: object
                        properties:
                          lookup_key:
                            type: string
                            description: A provided lookup key provided by you to help you identify the
                              file.
                            example: file_tag
                        required:
                          - lookup_key
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - filename
                      - mime_type
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: POST /files Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Upload a file to your archive. Use the file ID in subsequent requests.
      summary: Upload a File
      tags:
        - Files
      requestBody:
        description: POST /files request body
        content:
          multipart/form-data:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - type: object
                          properties: {}
                        - type: object
                          properties: {}
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    file:
                      type: string
                      format: binary
                      description: The binary representation of the file to upload.
                    lookup_key:
                      type: string
                      description: Arbitrary string which can be used to identify the file in future
                        requests.
                      example: my-file-tag
                  required:
                    - file
      security:
        - HTTP_1: []
    get:
      operationId: GetFiles
      responses:
        "200":
          description: GET /files Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - paginated_list
                    description: A paginated list of the file resource.
                  resource_type:
                    type: string
                    enum:
                      - file
                    description: Data contains the file resource.
                  data:
                    type: array
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                          format: cuid
                          description: The unique identifier of the file
                          example: cytp5m6ijs4rxs0erqsexample
                        resource_type:
                          type: string
                          enum:
                            - file
                        filename:
                          type: string
                          minLength: 1
                          description: The complete filename including the file extension
                          example: my-file.pdf
                        mime_type:
                          type: string
                          minLength: 1
                          description: The mime type of the file
                          example: application/pdf
                        url:
                          type: string
                          format: url
                          description: The signed read url of the file
                          example: https://zigned.se
                        metadata:
                          type: object
                          properties:
                            lookup_key:
                              type: string
                              description: A provided lookup key provided by you to help you identify the
                                file.
                              example: file_tag
                          required:
                            - lookup_key
                        created_at:
                          type: string
                          description: UTC datetime ISO string
                          example: 2024-01-01T00:00:00.000Z
                        updated_at:
                          type: string
                          description: UTC datetime ISO string
                          example: 2024-01-01T00:00:00.000Z
                      required:
                        - id
                        - resource_type
                        - filename
                        - mime_type
                        - created_at
                        - updated_at
                      description: The file resource
                    description: The resource data
                  pagination:
                    type: object
                    properties:
                      limit:
                        type: integer
                        format: int64
                        minimum: 0
                        exclusiveMinimum: true
                        maximum: 9007199254740991
                        exclusiveMaximum: false
                        description: The maximum number of items per page
                        example: 100
                      total_pages:
                        type: integer
                        format: int64
                        minimum: 0
                        exclusiveMinimum: true
                        maximum: 9007199254740991
                        exclusiveMaximum: false
                        description: The total number of pages
                        example: 10
                      page:
                        type: integer
                        format: int64
                        minimum: 0
                        exclusiveMinimum: true
                        maximum: 9007199254740991
                        exclusiveMaximum: false
                        description: The current page number
                        example: 1
                      total_results:
                        type: integer
                        format: int64
                        minimum: 0
                        exclusiveMinimum: false
                        maximum: 9007199254740991
                        exclusiveMaximum: false
                        description: The total number of results
                        example: 1000
                    required:
                      - limit
                      - total_pages
                      - page
                      - total_results
                    description: Contains the pagination meta data
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
                  - pagination
        "400":
          description: GET /files Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Retrieves a paginated list of all files uploaded by the client or user
      summary: List Files
      parameters:
        - name: limit
          in: query
          required: false
          description: GET /files parameter
          schema:
            type: string
            default: "50"
            example: "50"
        - name: page
          in: query
          required: false
          description: The page of agreements to return. Default 1
          schema:
            type: string
            default: "1"
            description: The page of agreements to return. Default 1
            example: "1"
        - name: order_by
          in: query
          required: false
          description: The files are ordered by date in descending order by default.
          schema:
            type: string
            enum:
              - desc
              - asc
            description: The files are ordered by date in descending order by default.
        - name: start_date
          in: query
          required: false
          description: The earliest creation date of the files to return.
          schema:
            description: The earliest creation date of the files to return.
            type: string
            format: date-time
            pattern: ^\d{4}-\d{2}-\d{2}(T\d{2}:\d{2}:\d{2}(\.\d+)?)?Z?$
            externalDocs:
              url: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString
        - name: end_date
          in: query
          required: false
          description: The latest creation date of the files to return.
          schema:
            description: The latest creation date of the files to return.
            type: string
            format: date-time
            pattern: ^\d{4}-\d{2}-\d{2}(T\d{2}:\d{2}:\d{2}(\.\d+)?)?Z?$
            externalDocs:
              url: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString
        - name: mime_type
          in: query
          required: false
          description: Filters the file list for the specific mimetype.
          schema:
            type: string
            enum:
              - application/pdf
              - image/png
              - image/jpg
            description: Filters the file list for the specific mimetype.
        - name: lookup_key
          in: query
          required: false
          description: The lookup key of the files to return
          schema:
            type: string
            description: The lookup key of the files to return
      security:
        - HTTP_1: []
  /files/{file_id}:
    delete:
      operationId: DeleteFilesFileId
      responses:
        "200":
          description: DELETE /files/:file_id Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - deleted
                    description: Returns a single object of the file resource which was deleted.
                  resource_type:
                    type: string
                    enum:
                      - file
                    description: Data contains the file resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the file
                        example: cytp5m6ijs4rxs0erqsexample
                      resource_type:
                        type: string
                        enum:
                          - file
                      filename:
                        type: string
                        minLength: 1
                        description: The complete filename including the file extension
                        example: my-file.pdf
                      mime_type:
                        type: string
                        minLength: 1
                        description: The mime type of the file
                        example: application/pdf
                      url:
                        type: string
                        format: url
                        description: The signed read url of the file
                        example: https://zigned.se
                      metadata:
                        type: object
                        properties:
                          lookup_key:
                            type: string
                            description: A provided lookup key provided by you to help you identify the
                              file.
                            example: file_tag
                        required:
                          - lookup_key
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - filename
                      - mime_type
                      - created_at
                      - updated_at
                    description: The resource data that was deleted.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: DELETE /files/:file_id Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Delete a file uploaded by the authenticated client or user.
      summary: Delete a File
      tags:
        - Files
      parameters:
        - name: file_id
          in: path
          required: true
          description: DELETE /files/:file_id parameter
          schema:
            type: string
            format: cuid
            example: cs6oqwqpspjgswlxuxkexample
      security:
        - HTTP_1: []
    get:
      operationId: GetFilesFileId
      responses:
        "200":
          description: GET /files/:file_id Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the file resource.
                  resource_type:
                    type: string
                    enum:
                      - file
                    description: Data contains the file resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the file
                        example: cytp5m6ijs4rxs0erqsexample
                      resource_type:
                        type: string
                        enum:
                          - file
                      filename:
                        type: string
                        minLength: 1
                        description: The complete filename including the file extension
                        example: my-file.pdf
                      mime_type:
                        type: string
                        minLength: 1
                        description: The mime type of the file
                        example: application/pdf
                      url:
                        type: string
                        format: url
                        description: The signed read url of the file
                        example: https://zigned.se
                      metadata:
                        type: object
                        properties:
                          lookup_key:
                            type: string
                            description: A provided lookup key provided by you to help you identify the
                              file.
                            example: file_tag
                        required:
                          - lookup_key
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - filename
                      - mime_type
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: GET /files/:file_id Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Retrieve a file uploaded by the authenticated client or user
      summary: Retrieve a File
      parameters:
        - name: file_id
          in: path
          required: true
          description: GET /files/:file_id parameter
          schema:
            type: string
            format: cuid
            example: cvhzivrkxybcoykmcurexample
      security:
        - HTTP_1: []
  /themes:
    post:
      operationId: PostThemes
      responses:
        "200":
          description: POST /themes Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the theme resource.
                  resource_type:
                    type: string
                    enum:
                      - theme
                    description: Data contains the theme resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the theme
                        example: coerir2amisfebqzdooexample
                      resource_type:
                        type: string
                        enum:
                          - theme
                      logo:
                        type: object
                        properties:
                          version:
                            type: string
                            enum:
                              - "1.0"
                            description: The version of the response schema
                          result_type:
                            type: string
                            enum:
                              - single
                            description: A single object of the file resource.
                          resource_type:
                            type: string
                            enum:
                              - file
                            description: Data contains the file resource.
                          data:
                            type: object
                            properties:
                              id:
                                type: string
                                format: cuid
                                description: The unique identifier of the file
                                example: cytp5m6ijs4rxs0erqsexample
                              resource_type:
                                type: string
                                enum:
                                  - file
                              filename:
                                type: string
                                minLength: 1
                                description: The complete filename including the file extension
                                example: my-file.pdf
                              mime_type:
                                type: string
                                minLength: 1
                                description: The mime type of the file
                                example: application/pdf
                              url:
                                type: string
                                format: url
                                description: The signed read url of the file
                                example: https://zigned.se
                              metadata:
                                type: object
                                properties:
                                  lookup_key:
                                    type: string
                                    description: A provided lookup key provided by you to help you identify the
                                      file.
                                    example: file_tag
                                required:
                                  - lookup_key
                              created_at:
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                              updated_at:
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                            required:
                              - id
                              - resource_type
                              - filename
                              - mime_type
                              - created_at
                              - updated_at
                            description: The resource data.
                        required:
                          - version
                          - result_type
                          - resource_type
                          - data
                        description: The logo of the theme. This is displayed to the user in all
                          communication and touch points.
                      icon:
                        type: object
                        properties:
                          version:
                            type: string
                            enum:
                              - "1.0"
                            description: The version of the response schema
                          result_type:
                            type: string
                            enum:
                              - single
                            description: A single object of the file resource.
                          resource_type:
                            type: string
                            enum:
                              - file
                            description: Data contains the file resource.
                          data:
                            type: object
                            properties:
                              id:
                                type: string
                                format: cuid
                                description: The unique identifier of the file
                                example: cytp5m6ijs4rxs0erqsexample
                              resource_type:
                                type: string
                                enum:
                                  - file
                              filename:
                                type: string
                                minLength: 1
                                description: The complete filename including the file extension
                                example: my-file.pdf
                              mime_type:
                                type: string
                                minLength: 1
                                description: The mime type of the file
                                example: application/pdf
                              url:
                                type: string
                                format: url
                                description: The signed read url of the file
                                example: https://zigned.se
                              metadata:
                                type: object
                                properties:
                                  lookup_key:
                                    type: string
                                    description: A provided lookup key provided by you to help you identify the
                                      file.
                                    example: file_tag
                                required:
                                  - lookup_key
                              created_at:
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                              updated_at:
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                            required:
                              - id
                              - resource_type
                              - filename
                              - mime_type
                              - created_at
                              - updated_at
                            description: The resource data.
                        required:
                          - version
                          - result_type
                          - resource_type
                          - data
                        description: The icon of the theme. This is used for the favicon.
                      primary_color:
                        type: string
                        default: "#000000"
                        description: The primary color used to create the color palette in the signing
                          room.
                        example: "#000000"
                      metadata:
                        type: object
                        properties:
                          lookup_key:
                            type: string
                            description: A provided lookup key provided by you to help you identify the
                              theme.
                            example: your_internal_customer_id
                        required:
                          - lookup_key
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - logo
                      - icon
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: POST /themes Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Create a new theme. Use the theme ID in subsequent requests.
      summary: Create a Theme
      tags:
        - Themes
      requestBody:
        description: POST /themes request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - type: object
                          properties: {}
                        - type: object
                          properties: {}
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    primary_color:
                      type: string
                      minLength: 1
                      default: "#000000"
                      description: The primary color used to generate the color palette
                      example: "#000000"
                    logo_file_id:
                      type: string
                      format: cuid
                      minLength: 1
                      description: The ID of the uploaded logo. Upload the logo to the `/files`
                        endpoint. Must be a `jpeg` or `png` file.
                      example: cgifxtqmqqtqggoorioexample
                    icon_file_id:
                      type: string
                      format: cuid
                      minLength: 1
                      description: The ID of the uploaded icon. Upload the icon to the `/files`
                        endpoint. Must be a `jpeg` or `png` file.
                      example: cj6n7b2sfkkbfbvmaj0example
                    lookup_key:
                      type: string
                      description: Arbitrary string which can be used to identify the theme in future
                        requests.
                      example: my_internal_customer_id
                  required:
                    - logo_file_id
                    - icon_file_id
      security:
        - HTTP_1: []
    get:
      operationId: GetThemes
      responses:
        "200":
          description: GET /themes Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - paginated_list
                    description: A paginated list of the theme resource.
                  resource_type:
                    type: string
                    enum:
                      - theme
                    description: Data contains the theme resource.
                  data:
                    type: array
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                          format: cuid
                          description: The unique identifier of the theme
                          example: coerir2amisfebqzdooexample
                        resource_type:
                          type: string
                          enum:
                            - theme
                        logo:
                          type: object
                          properties:
                            version:
                              type: string
                              enum:
                                - "1.0"
                              description: The version of the response schema
                            result_type:
                              type: string
                              enum:
                                - single
                              description: A single object of the file resource.
                            resource_type:
                              type: string
                              enum:
                                - file
                              description: Data contains the file resource.
                            data:
                              type: object
                              properties:
                                id:
                                  type: string
                                  format: cuid
                                  description: The unique identifier of the file
                                  example: cytp5m6ijs4rxs0erqsexample
                                resource_type:
                                  type: string
                                  enum:
                                    - file
                                filename:
                                  type: string
                                  minLength: 1
                                  description: The complete filename including the file extension
                                  example: my-file.pdf
                                mime_type:
                                  type: string
                                  minLength: 1
                                  description: The mime type of the file
                                  example: application/pdf
                                url:
                                  type: string
                                  format: url
                                  description: The signed read url of the file
                                  example: https://zigned.se
                                metadata:
                                  type: object
                                  properties:
                                    lookup_key:
                                      type: string
                                      description: A provided lookup key provided by you to help you identify the
                                        file.
                                      example: file_tag
                                  required:
                                    - lookup_key
                                created_at:
                                  type: string
                                  description: UTC datetime ISO string
                                  example: 2024-01-01T00:00:00.000Z
                                updated_at:
                                  type: string
                                  description: UTC datetime ISO string
                                  example: 2024-01-01T00:00:00.000Z
                              required:
                                - id
                                - resource_type
                                - filename
                                - mime_type
                                - created_at
                                - updated_at
                              description: The resource data.
                          required:
                            - version
                            - result_type
                            - resource_type
                            - data
                          description: The logo of the theme. This is displayed to the user in all
                            communication and touch points.
                        icon:
                          type: object
                          properties:
                            version:
                              type: string
                              enum:
                                - "1.0"
                              description: The version of the response schema
                            result_type:
                              type: string
                              enum:
                                - single
                              description: A single object of the file resource.
                            resource_type:
                              type: string
                              enum:
                                - file
                              description: Data contains the file resource.
                            data:
                              type: object
                              properties:
                                id:
                                  type: string
                                  format: cuid
                                  description: The unique identifier of the file
                                  example: cytp5m6ijs4rxs0erqsexample
                                resource_type:
                                  type: string
                                  enum:
                                    - file
                                filename:
                                  type: string
                                  minLength: 1
                                  description: The complete filename including the file extension
                                  example: my-file.pdf
                                mime_type:
                                  type: string
                                  minLength: 1
                                  description: The mime type of the file
                                  example: application/pdf
                                url:
                                  type: string
                                  format: url
                                  description: The signed read url of the file
                                  example: https://zigned.se
                                metadata:
                                  type: object
                                  properties:
                                    lookup_key:
                                      type: string
                                      description: A provided lookup key provided by you to help you identify the
                                        file.
                                      example: file_tag
                                  required:
                                    - lookup_key
                                created_at:
                                  type: string
                                  description: UTC datetime ISO string
                                  example: 2024-01-01T00:00:00.000Z
                                updated_at:
                                  type: string
                                  description: UTC datetime ISO string
                                  example: 2024-01-01T00:00:00.000Z
                              required:
                                - id
                                - resource_type
                                - filename
                                - mime_type
                                - created_at
                                - updated_at
                              description: The resource data.
                          required:
                            - version
                            - result_type
                            - resource_type
                            - data
                          description: The icon of the theme. This is used for the favicon.
                        primary_color:
                          type: string
                          default: "#000000"
                          description: The primary color used to create the color palette in the signing
                            room.
                          example: "#000000"
                        metadata:
                          type: object
                          properties:
                            lookup_key:
                              type: string
                              description: A provided lookup key provided by you to help you identify the
                                theme.
                              example: your_internal_customer_id
                          required:
                            - lookup_key
                        created_at:
                          type: string
                          description: UTC datetime ISO string
                          example: 2024-01-01T00:00:00.000Z
                        updated_at:
                          type: string
                          description: UTC datetime ISO string
                          example: 2024-01-01T00:00:00.000Z
                      required:
                        - id
                        - resource_type
                        - logo
                        - icon
                        - created_at
                        - updated_at
                      description: The theme resource
                    description: The resource data
                  pagination:
                    type: object
                    properties:
                      limit:
                        type: integer
                        format: int64
                        minimum: 0
                        exclusiveMinimum: true
                        maximum: 9007199254740991
                        exclusiveMaximum: false
                        description: The maximum number of items per page
                        example: 100
                      total_pages:
                        type: integer
                        format: int64
                        minimum: 0
                        exclusiveMinimum: true
                        maximum: 9007199254740991
                        exclusiveMaximum: false
                        description: The total number of pages
                        example: 10
                      page:
                        type: integer
                        format: int64
                        minimum: 0
                        exclusiveMinimum: true
                        maximum: 9007199254740991
                        exclusiveMaximum: false
                        description: The current page number
                        example: 1
                      total_results:
                        type: integer
                        format: int64
                        minimum: 0
                        exclusiveMinimum: false
                        maximum: 9007199254740991
                        exclusiveMaximum: false
                        description: The total number of results
                        example: 1000
                    required:
                      - limit
                      - total_pages
                      - page
                      - total_results
                    description: Contains the pagination meta data
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
                  - pagination
        "400":
          description: GET /themes Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Retrieves a paginated list of all themes created for the account
      summary: List Themes
      tags:
        - Themes
      parameters:
        - name: limit
          in: query
          required: false
          description: GET /themes parameter
          schema:
            type: string
            default: "50"
            example: "50"
        - name: page
          in: query
          required: false
          description: GET /themes parameter
          schema:
            type: string
            default: "1"
            example: "1"
        - name: order_by
          in: query
          required: false
          description: GET /themes parameter
          schema:
            type: string
            enum:
              - desc
              - asc
        - name: start_date
          in: query
          required: false
          description: YYYY-MM-DDTHH:mm:ss.sssZ
          schema:
            description: YYYY-MM-DDTHH:mm:ss.sssZ
            type: string
            format: date-time
            pattern: ^\d{4}-\d{2}-\d{2}(T\d{2}:\d{2}:\d{2}(\.\d+)?)?Z?$
            externalDocs:
              url: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString
        - name: end_date
          in: query
          required: false
          description: YYYY-MM-DDTHH:mm:ss.sssZ
          schema:
            description: YYYY-MM-DDTHH:mm:ss.sssZ
            type: string
            format: date-time
            pattern: ^\d{4}-\d{2}-\d{2}(T\d{2}:\d{2}:\d{2}(\.\d+)?)?Z?$
            externalDocs:
              url: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString
        - name: lookup_key
          in: query
          required: false
          description: The lookup key of the themes to return
          schema:
            type: string
            description: The lookup key of the themes to return
      security:
        - HTTP_1: []
  /themes/{theme_id}:
    delete:
      operationId: DeleteThemesThemeId
      responses:
        "200":
          description: DELETE /themes/:theme_id Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - deleted
                    description: Returns a single object of the theme resource which was deleted.
                  resource_type:
                    type: string
                    enum:
                      - theme
                    description: Data contains the theme resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the theme
                        example: coerir2amisfebqzdooexample
                      resource_type:
                        type: string
                        enum:
                          - theme
                      logo:
                        type: object
                        properties:
                          version:
                            type: string
                            enum:
                              - "1.0"
                            description: The version of the response schema
                          result_type:
                            type: string
                            enum:
                              - single
                            description: A single object of the file resource.
                          resource_type:
                            type: string
                            enum:
                              - file
                            description: Data contains the file resource.
                          data:
                            type: object
                            properties:
                              id:
                                type: string
                                format: cuid
                                description: The unique identifier of the file
                                example: cytp5m6ijs4rxs0erqsexample
                              resource_type:
                                type: string
                                enum:
                                  - file
                              filename:
                                type: string
                                minLength: 1
                                description: The complete filename including the file extension
                                example: my-file.pdf
                              mime_type:
                                type: string
                                minLength: 1
                                description: The mime type of the file
                                example: application/pdf
                              url:
                                type: string
                                format: url
                                description: The signed read url of the file
                                example: https://zigned.se
                              metadata:
                                type: object
                                properties:
                                  lookup_key:
                                    type: string
                                    description: A provided lookup key provided by you to help you identify the
                                      file.
                                    example: file_tag
                                required:
                                  - lookup_key
                              created_at:
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                              updated_at:
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                            required:
                              - id
                              - resource_type
                              - filename
                              - mime_type
                              - created_at
                              - updated_at
                            description: The resource data.
                        required:
                          - version
                          - result_type
                          - resource_type
                          - data
                        description: The logo of the theme. This is displayed to the user in all
                          communication and touch points.
                      icon:
                        type: object
                        properties:
                          version:
                            type: string
                            enum:
                              - "1.0"
                            description: The version of the response schema
                          result_type:
                            type: string
                            enum:
                              - single
                            description: A single object of the file resource.
                          resource_type:
                            type: string
                            enum:
                              - file
                            description: Data contains the file resource.
                          data:
                            type: object
                            properties:
                              id:
                                type: string
                                format: cuid
                                description: The unique identifier of the file
                                example: cytp5m6ijs4rxs0erqsexample
                              resource_type:
                                type: string
                                enum:
                                  - file
                              filename:
                                type: string
                                minLength: 1
                                description: The complete filename including the file extension
                                example: my-file.pdf
                              mime_type:
                                type: string
                                minLength: 1
                                description: The mime type of the file
                                example: application/pdf
                              url:
                                type: string
                                format: url
                                description: The signed read url of the file
                                example: https://zigned.se
                              metadata:
                                type: object
                                properties:
                                  lookup_key:
                                    type: string
                                    description: A provided lookup key provided by you to help you identify the
                                      file.
                                    example: file_tag
                                required:
                                  - lookup_key
                              created_at:
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                              updated_at:
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                            required:
                              - id
                              - resource_type
                              - filename
                              - mime_type
                              - created_at
                              - updated_at
                            description: The resource data.
                        required:
                          - version
                          - result_type
                          - resource_type
                          - data
                        description: The icon of the theme. This is used for the favicon.
                      primary_color:
                        type: string
                        default: "#000000"
                        description: The primary color used to create the color palette in the signing
                          room.
                        example: "#000000"
                      metadata:
                        type: object
                        properties:
                          lookup_key:
                            type: string
                            description: A provided lookup key provided by you to help you identify the
                              theme.
                            example: your_internal_customer_id
                        required:
                          - lookup_key
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - logo
                      - icon
                      - created_at
                      - updated_at
                    description: The resource data that was deleted.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: DELETE /themes/:theme_id Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Deletes a theme created for the account associated with the
        authenticated client.
      summary: Delete a Theme
      tags:
        - Themes
      parameters:
        - name: theme_id
          in: path
          required: true
          description: The ID of the theme to delete
          schema:
            type: string
            format: cuid
            description: The ID of the theme to delete
            example: cheofunkzmcp72ar4ngexample
      security:
        - HTTP_1: []
    put:
      operationId: PutThemesThemeId
      responses:
        "200":
          description: PUT /themes/:theme_id Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the theme resource.
                  resource_type:
                    type: string
                    enum:
                      - theme
                    description: Data contains the theme resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the theme
                        example: coerir2amisfebqzdooexample
                      resource_type:
                        type: string
                        enum:
                          - theme
                      logo:
                        type: object
                        properties:
                          version:
                            type: string
                            enum:
                              - "1.0"
                            description: The version of the response schema
                          result_type:
                            type: string
                            enum:
                              - single
                            description: A single object of the file resource.
                          resource_type:
                            type: string
                            enum:
                              - file
                            description: Data contains the file resource.
                          data:
                            type: object
                            properties:
                              id:
                                type: string
                                format: cuid
                                description: The unique identifier of the file
                                example: cytp5m6ijs4rxs0erqsexample
                              resource_type:
                                type: string
                                enum:
                                  - file
                              filename:
                                type: string
                                minLength: 1
                                description: The complete filename including the file extension
                                example: my-file.pdf
                              mime_type:
                                type: string
                                minLength: 1
                                description: The mime type of the file
                                example: application/pdf
                              url:
                                type: string
                                format: url
                                description: The signed read url of the file
                                example: https://zigned.se
                              metadata:
                                type: object
                                properties:
                                  lookup_key:
                                    type: string
                                    description: A provided lookup key provided by you to help you identify the
                                      file.
                                    example: file_tag
                                required:
                                  - lookup_key
                              created_at:
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                              updated_at:
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                            required:
                              - id
                              - resource_type
                              - filename
                              - mime_type
                              - created_at
                              - updated_at
                            description: The resource data.
                        required:
                          - version
                          - result_type
                          - resource_type
                          - data
                        description: The logo of the theme. This is displayed to the user in all
                          communication and touch points.
                      icon:
                        type: object
                        properties:
                          version:
                            type: string
                            enum:
                              - "1.0"
                            description: The version of the response schema
                          result_type:
                            type: string
                            enum:
                              - single
                            description: A single object of the file resource.
                          resource_type:
                            type: string
                            enum:
                              - file
                            description: Data contains the file resource.
                          data:
                            type: object
                            properties:
                              id:
                                type: string
                                format: cuid
                                description: The unique identifier of the file
                                example: cytp5m6ijs4rxs0erqsexample
                              resource_type:
                                type: string
                                enum:
                                  - file
                              filename:
                                type: string
                                minLength: 1
                                description: The complete filename including the file extension
                                example: my-file.pdf
                              mime_type:
                                type: string
                                minLength: 1
                                description: The mime type of the file
                                example: application/pdf
                              url:
                                type: string
                                format: url
                                description: The signed read url of the file
                                example: https://zigned.se
                              metadata:
                                type: object
                                properties:
                                  lookup_key:
                                    type: string
                                    description: A provided lookup key provided by you to help you identify the
                                      file.
                                    example: file_tag
                                required:
                                  - lookup_key
                              created_at:
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                              updated_at:
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                            required:
                              - id
                              - resource_type
                              - filename
                              - mime_type
                              - created_at
                              - updated_at
                            description: The resource data.
                        required:
                          - version
                          - result_type
                          - resource_type
                          - data
                        description: The icon of the theme. This is used for the favicon.
                      primary_color:
                        type: string
                        default: "#000000"
                        description: The primary color used to create the color palette in the signing
                          room.
                        example: "#000000"
                      metadata:
                        type: object
                        properties:
                          lookup_key:
                            type: string
                            description: A provided lookup key provided by you to help you identify the
                              theme.
                            example: your_internal_customer_id
                        required:
                          - lookup_key
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - logo
                      - icon
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: PUT /themes/:theme_id Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Updates a theme created with the authenticated client
      summary: Update a Theme
      parameters:
        - name: theme_id
          in: path
          required: true
          description: The ID of the theme to retrieve
          schema:
            type: string
            format: cuid
            description: The ID of the theme to retrieve
            example: cy8cclcvaqxw6ltikpkexample
      requestBody:
        description: PUT /themes/:theme_id request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - allOf:
                            - type: object
                              properties: {}
                            - type: object
                              properties: {}
                        - type: object
                          properties: {}
                    - type: object
                      properties: {}
                      required: []
                - type: object
                  properties:
                    primary_color:
                      type: string
                      description: The primary color used to generate the color palette
                      example: "#000000"
                    logo_file_id:
                      type: string
                      format: cuid
                      description: The ID of the uploaded logo. Upload the logo to the `/files`
                        endpoint. Must be a `jpeg` or `png` file.
                      example: cqxu2vnwbwfyekgslfhexample
                    icon_file_id:
                      type: string
                      format: cuid
                      description: The ID of the uploaded icon. Upload the icon to the `/files`
                        endpoint. Must be a `jpeg` or `png` file.
                      example: cdrlifdlczbnlhosc8aexample
                    lookup_key:
                      type: string
                      description: Arbitrary string which can be used to identify the theme in future
                        requests.
                      example: my_internal_customer_id
                  required: []
      security:
        - HTTP_1: []
    get:
      operationId: GetThemesThemeId
      responses:
        "200":
          description: GET /themes/:theme_id Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the theme resource.
                  resource_type:
                    type: string
                    enum:
                      - theme
                    description: Data contains the theme resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the theme
                        example: coerir2amisfebqzdooexample
                      resource_type:
                        type: string
                        enum:
                          - theme
                      logo:
                        type: object
                        properties:
                          version:
                            type: string
                            enum:
                              - "1.0"
                            description: The version of the response schema
                          result_type:
                            type: string
                            enum:
                              - single
                            description: A single object of the file resource.
                          resource_type:
                            type: string
                            enum:
                              - file
                            description: Data contains the file resource.
                          data:
                            type: object
                            properties:
                              id:
                                type: string
                                format: cuid
                                description: The unique identifier of the file
                                example: cytp5m6ijs4rxs0erqsexample
                              resource_type:
                                type: string
                                enum:
                                  - file
                              filename:
                                type: string
                                minLength: 1
                                description: The complete filename including the file extension
                                example: my-file.pdf
                              mime_type:
                                type: string
                                minLength: 1
                                description: The mime type of the file
                                example: application/pdf
                              url:
                                type: string
                                format: url
                                description: The signed read url of the file
                                example: https://zigned.se
                              metadata:
                                type: object
                                properties:
                                  lookup_key:
                                    type: string
                                    description: A provided lookup key provided by you to help you identify the
                                      file.
                                    example: file_tag
                                required:
                                  - lookup_key
                              created_at:
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                              updated_at:
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                            required:
                              - id
                              - resource_type
                              - filename
                              - mime_type
                              - created_at
                              - updated_at
                            description: The resource data.
                        required:
                          - version
                          - result_type
                          - resource_type
                          - data
                        description: The logo of the theme. This is displayed to the user in all
                          communication and touch points.
                      icon:
                        type: object
                        properties:
                          version:
                            type: string
                            enum:
                              - "1.0"
                            description: The version of the response schema
                          result_type:
                            type: string
                            enum:
                              - single
                            description: A single object of the file resource.
                          resource_type:
                            type: string
                            enum:
                              - file
                            description: Data contains the file resource.
                          data:
                            type: object
                            properties:
                              id:
                                type: string
                                format: cuid
                                description: The unique identifier of the file
                                example: cytp5m6ijs4rxs0erqsexample
                              resource_type:
                                type: string
                                enum:
                                  - file
                              filename:
                                type: string
                                minLength: 1
                                description: The complete filename including the file extension
                                example: my-file.pdf
                              mime_type:
                                type: string
                                minLength: 1
                                description: The mime type of the file
                                example: application/pdf
                              url:
                                type: string
                                format: url
                                description: The signed read url of the file
                                example: https://zigned.se
                              metadata:
                                type: object
                                properties:
                                  lookup_key:
                                    type: string
                                    description: A provided lookup key provided by you to help you identify the
                                      file.
                                    example: file_tag
                                required:
                                  - lookup_key
                              created_at:
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                              updated_at:
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                            required:
                              - id
                              - resource_type
                              - filename
                              - mime_type
                              - created_at
                              - updated_at
                            description: The resource data.
                        required:
                          - version
                          - result_type
                          - resource_type
                          - data
                        description: The icon of the theme. This is used for the favicon.
                      primary_color:
                        type: string
                        default: "#000000"
                        description: The primary color used to create the color palette in the signing
                          room.
                        example: "#000000"
                      metadata:
                        type: object
                        properties:
                          lookup_key:
                            type: string
                            description: A provided lookup key provided by you to help you identify the
                              theme.
                            example: your_internal_customer_id
                        required:
                          - lookup_key
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - logo
                      - icon
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: GET /themes/:theme_id Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Retrieves a theme created with the authenticated client
      summary: Retrieve a Theme
      parameters:
        - name: theme_id
          in: path
          required: true
          description: The ID of the theme to retrieve
          schema:
            type: string
            format: cuid
            description: The ID of the theme to retrieve
            example: chsr179hy5ch7dsbng2example
      security:
        - HTTP_1: []
  /webhooks:
    post:
      operationId: PostWebhooks
      responses:
        "200":
          description: POST /webhooks Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the webhook resource.
                  resource_type:
                    type: string
                    enum:
                      - webhook
                    description: Data contains the webhook resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the webhook endpoint
                        example: cxsbn6hqi1olfgumooyexample
                      name:
                        type: string
                        description: The name of the webhook. This is only used to help you identify the
                          webhook.
                        example: My webhook endpoint
                      resource_type:
                        type: string
                        enum:
                          - webhook
                      url:
                        type: string
                        format: url
                        description: The URL of the webhook endpoint. Must be HTTPS.
                        example: https://www.example.com
                      secret:
                        type: string
                        description: The webhook secret. This is used tfor the HMAC signature of the
                          webhook request, which is included in a header called
                          x-zigned-request-signature
                      type:
                        type: string
                        enum:
                          - production
                          - development
                        description: The type of the webhook endpoint. Development webhooks will only
                          receive events from agreements with test_mode set to
                          true.
                      scope:
                        discriminator:
                          propertyName: type
                        oneOf:
                          - type: object
                            properties:
                              type:
                                type: string
                                enum:
                                  - user
                              user_id:
                                type: string
                                format: cuid
                                description: The unique identifier of the user
                                example: csnmyjyztt2z356qdyaexample
                            required:
                              - type
                              - user_id
                          - type: object
                            properties:
                              type:
                                type: string
                                enum:
                                  - global
                            required:
                              - type
                        description: The scope of the webhook notifications. If set to user, only events
                          related to the agreements created by the scoped user
                          will be sent. If set to global, all events will be
                          sent.
                      status:
                        type: string
                        enum:
                          - active
                          - inactive
                        description: The status of the webhook. Only active webhooks will receive
                          notifications.
                      subscriptions:
                        type: array
                        items:
                          type: string
                          enum:
                            - agreement.draft.created
                            - agreement.draft.updated
                            - agreement.lifecycle.pending
                            - agreement.lifecycle.fulfilled
                            - agreement.lifecycle.finalized
                            - agreement.lifecycle.cancelled
                            - agreement.lifecycle.opened
                            - agreement.lifecycle.expired
                            - agreement.validation.started
                            - agreement.validation.completed
                            - agreement.validation.failed
                            - agreement.generation.restarted
                            - agreement.generation.started
                            - agreement.generation.completed
                            - agreement.generation.failed
                            - agreement.audit_trail_verification.started
                            - agreement.audit_trail_verification.completed
                            - agreement.audit_trail_verification.failed
                            - agreement.pdf_verification.started
                            - agreement.pdf_verification.completed
                            - agreement.pdf_verification.failed
                            - agreement.deletion.scheduled
                            - agreement.deletion.cancelled
                            - agreement.deletion.completed
                            - participant.draft.created
                            - participant.draft.updated
                            - participant.identity_enforcement.passed
                            - participant.identity_enforcement.failed
                            - participant.lifecycle.received_invitation
                            - participant.lifecycle.fulfilled
                            - participant.lifecycle.forwarded
                            - sign_event.signing_room.entered
                            - sign_event.signing_room.left
                            - sign_event.sign.initiated_sign
                            - sign_event.sign.cancelled_sign
                            - sign_event.sign.completed_sign
                            - sign_event.sign.requested_otp
                            - sign_event.sign.received_otp
                            - sign_event.sign.failed_to_receive_otp
                            - sign_event.sign.confirm_otp_failed
                            - sign_event.sign.confirmed_otp
                            - sign_event.sign.changed_email_for_otp
                            - sign_event.sign.forwarded_link
                            - sign_event.approval.approved
                            - sign_event.approval.disapproved
                            - sign_event.document.began_scroll
                            - sign_event.document.scrolled_to_bottom
                            - sign_event.document.clicked_to_view
                            - sign_event.document.loaded
                            - sign_event.document.failed_to_load
                            - sign_event.document.downloaded
                            - sign_event.error.reset
                            - email_event.agreement_invitation.delivery_failed
                            - email_event.agreement_invitation.delivered
                            - email_event.agreement_invitation.all_delivered
                            - email_event.agreement_observer_invitation.delivery_failed
                            - email_event.agreement_observer_invitation.delivered
                            - email_event.agreement_observer_invitation.all_delivered
                            - email_event.agreement_reminder.delivery_failed
                            - email_event.agreement_reminder.delivered
                            - email_event.agreement_reminder.all_delivered
                            - email_event.agreement_forwarded.delivery_failed
                            - email_event.agreement_forwarded.delivered
                            - email_event.agreement_forwarded.all_delivered
                            - email_event.agreement_finalized.delivery_failed
                            - email_event.agreement_finalized.delivered
                            - email_event.agreement_finalized.all_delivered
                            - email_event.agreement_cancelled.delivery_failed
                            - email_event.agreement_cancelled.delivered
                            - email_event.agreement_cancelled.all_delivered
                            - email_event.agreement_paused.delivery_failed
                            - email_event.agreement_paused.delivered
                            - email_event.agreement_paused.all_delivered
                            - observer.draft.created
                            - observer.draft.updated
                        description: The events that the webhook is subscribed to.
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - url
                      - secret
                      - type
                      - scope
                      - status
                      - subscriptions
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: POST /webhooks Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Create a new webhook. Use the webhook ID in subsequent requests.
      summary: Create a Webhook
      tags:
        - Webhooks
      requestBody:
        description: POST /webhooks request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - type: object
                          properties: {}
                        - type: object
                          properties: {}
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    url:
                      type: string
                      format: url
                      description: The URL which will receive the webhook notifications. Must be HTTPS
                      example: https://www.example.com
                    name:
                      type: string
                      description: The name of the webhook. If omitted, a name will be automatically
                        generated. The name is only to help you identify the
                        webhook in responses.
                      example: My webhook
                    status:
                      type: string
                      enum:
                        - active
                        - inactive
                      default: inactive
                      description: The status of the webhook. Only active webhooks receive
                        notifications.
                    type:
                      type: string
                      enum:
                        - production
                        - development
                      default: production
                      description: The type of the webhook. If set to development, the webhooks will
                        only be notified of agreements with test_mode set to
                        true.
                    scope:
                      type: string
                      enum:
                        - global
                        - user
                        - client
                      default: client
                      description: The scope of the webhook. If set to global, the webhook will be
                        notified of all events for all agreements created by any
                        user associated with the account. If set to user or
                        client, the webhook will only be notified of agreements
                        created by the associated user/client. **Note:** A
                        global webhook will always use the latest api version
                        and could introduce unexpected data into your
                        integration. Client/User scoped webhooks will only send
                        data supported up to the api version specificed in your
                        accounts.
                    subscriptions:
                      type: array
                      items:
                        type: string
                        enum:
                          - agreement.draft.created
                          - agreement.draft.updated
                          - agreement.lifecycle.pending
                          - agreement.lifecycle.fulfilled
                          - agreement.lifecycle.finalized
                          - agreement.lifecycle.cancelled
                          - agreement.lifecycle.opened
                          - agreement.lifecycle.expired
                          - agreement.validation.started
                          - agreement.validation.completed
                          - agreement.validation.failed
                          - agreement.generation.restarted
                          - agreement.generation.started
                          - agreement.generation.completed
                          - agreement.generation.failed
                          - agreement.audit_trail_verification.started
                          - agreement.audit_trail_verification.completed
                          - agreement.audit_trail_verification.failed
                          - agreement.pdf_verification.started
                          - agreement.pdf_verification.completed
                          - agreement.pdf_verification.failed
                          - agreement.deletion.scheduled
                          - agreement.deletion.cancelled
                          - agreement.deletion.completed
                          - participant.draft.created
                          - participant.draft.updated
                          - participant.identity_enforcement.passed
                          - participant.identity_enforcement.failed
                          - participant.lifecycle.received_invitation
                          - participant.lifecycle.fulfilled
                          - participant.lifecycle.forwarded
                          - sign_event.signing_room.entered
                          - sign_event.signing_room.left
                          - sign_event.sign.initiated_sign
                          - sign_event.sign.cancelled_sign
                          - sign_event.sign.completed_sign
                          - sign_event.sign.requested_otp
                          - sign_event.sign.received_otp
                          - sign_event.sign.failed_to_receive_otp
                          - sign_event.sign.confirm_otp_failed
                          - sign_event.sign.confirmed_otp
                          - sign_event.sign.changed_email_for_otp
                          - sign_event.sign.forwarded_link
                          - sign_event.approval.approved
                          - sign_event.approval.disapproved
                          - sign_event.document.began_scroll
                          - sign_event.document.scrolled_to_bottom
                          - sign_event.document.clicked_to_view
                          - sign_event.document.loaded
                          - sign_event.document.failed_to_load
                          - sign_event.document.downloaded
                          - sign_event.error.reset
                          - email_event.agreement_invitation.delivery_failed
                          - email_event.agreement_invitation.delivered
                          - email_event.agreement_invitation.all_delivered
                          - email_event.agreement_observer_invitation.delivery_failed
                          - email_event.agreement_observer_invitation.delivered
                          - email_event.agreement_observer_invitation.all_delivered
                          - email_event.agreement_reminder.delivery_failed
                          - email_event.agreement_reminder.delivered
                          - email_event.agreement_reminder.all_delivered
                          - email_event.agreement_forwarded.delivery_failed
                          - email_event.agreement_forwarded.delivered
                          - email_event.agreement_forwarded.all_delivered
                          - email_event.agreement_finalized.delivery_failed
                          - email_event.agreement_finalized.delivered
                          - email_event.agreement_finalized.all_delivered
                          - email_event.agreement_cancelled.delivery_failed
                          - email_event.agreement_cancelled.delivered
                          - email_event.agreement_cancelled.all_delivered
                          - email_event.agreement_paused.delivery_failed
                          - email_event.agreement_paused.delivered
                          - email_event.agreement_paused.all_delivered
                          - observer.draft.created
                          - observer.draft.updated
                      default: []
                      description: The events to subscribe to
                  required:
                    - url
      security:
        - HTTP_1: []
    get:
      operationId: GetWebhooks
      responses:
        "200":
          description: GET /webhooks Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - list
                    description: A non-paginated list of the webhook resource.
                  resource_type:
                    type: string
                    enum:
                      - webhook
                    description: Data contains the webhook resource.
                  data:
                    $ref: "#/components/schemas/2048581c137c5b2130eb860e3ae37da196dfc25b"
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: GET /webhooks Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Lists all webhooks created for the account.
      summary: List Webhooks
      tags:
        - Webhooks
      security:
        - HTTP_1: []
  /webhooks/{webhook_id}:
    delete:
      operationId: DeleteWebhooksWebhookId
      responses:
        "200":
          description: DELETE /webhooks/:webhook_id Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - deleted
                    description: Returns a single object of the webhook resource which was deleted.
                  resource_type:
                    type: string
                    enum:
                      - webhook
                    description: Data contains the webhook resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the webhook endpoint
                        example: cxsbn6hqi1olfgumooyexample
                      name:
                        type: string
                        description: The name of the webhook. This is only used to help you identify the
                          webhook.
                        example: My webhook endpoint
                      resource_type:
                        type: string
                        enum:
                          - webhook
                      url:
                        type: string
                        format: url
                        description: The URL of the webhook endpoint. Must be HTTPS.
                        example: https://www.example.com
                      secret:
                        type: string
                        description: The webhook secret. This is used tfor the HMAC signature of the
                          webhook request, which is included in a header called
                          x-zigned-request-signature
                      type:
                        type: string
                        enum:
                          - production
                          - development
                        description: The type of the webhook endpoint. Development webhooks will only
                          receive events from agreements with test_mode set to
                          true.
                      scope:
                        discriminator:
                          propertyName: type
                        oneOf:
                          - type: object
                            properties:
                              type:
                                type: string
                                enum:
                                  - user
                              user_id:
                                type: string
                                format: cuid
                                description: The unique identifier of the user
                                example: csnmyjyztt2z356qdyaexample
                            required:
                              - type
                              - user_id
                          - type: object
                            properties:
                              type:
                                type: string
                                enum:
                                  - global
                            required:
                              - type
                        description: The scope of the webhook notifications. If set to user, only events
                          related to the agreements created by the scoped user
                          will be sent. If set to global, all events will be
                          sent.
                      status:
                        type: string
                        enum:
                          - active
                          - inactive
                        description: The status of the webhook. Only active webhooks will receive
                          notifications.
                      subscriptions:
                        type: array
                        items:
                          type: string
                          enum:
                            - agreement.draft.created
                            - agreement.draft.updated
                            - agreement.lifecycle.pending
                            - agreement.lifecycle.fulfilled
                            - agreement.lifecycle.finalized
                            - agreement.lifecycle.cancelled
                            - agreement.lifecycle.opened
                            - agreement.lifecycle.expired
                            - agreement.validation.started
                            - agreement.validation.completed
                            - agreement.validation.failed
                            - agreement.generation.restarted
                            - agreement.generation.started
                            - agreement.generation.completed
                            - agreement.generation.failed
                            - agreement.audit_trail_verification.started
                            - agreement.audit_trail_verification.completed
                            - agreement.audit_trail_verification.failed
                            - agreement.pdf_verification.started
                            - agreement.pdf_verification.completed
                            - agreement.pdf_verification.failed
                            - agreement.deletion.scheduled
                            - agreement.deletion.cancelled
                            - agreement.deletion.completed
                            - participant.draft.created
                            - participant.draft.updated
                            - participant.identity_enforcement.passed
                            - participant.identity_enforcement.failed
                            - participant.lifecycle.received_invitation
                            - participant.lifecycle.fulfilled
                            - participant.lifecycle.forwarded
                            - sign_event.signing_room.entered
                            - sign_event.signing_room.left
                            - sign_event.sign.initiated_sign
                            - sign_event.sign.cancelled_sign
                            - sign_event.sign.completed_sign
                            - sign_event.sign.requested_otp
                            - sign_event.sign.received_otp
                            - sign_event.sign.failed_to_receive_otp
                            - sign_event.sign.confirm_otp_failed
                            - sign_event.sign.confirmed_otp
                            - sign_event.sign.changed_email_for_otp
                            - sign_event.sign.forwarded_link
                            - sign_event.approval.approved
                            - sign_event.approval.disapproved
                            - sign_event.document.began_scroll
                            - sign_event.document.scrolled_to_bottom
                            - sign_event.document.clicked_to_view
                            - sign_event.document.loaded
                            - sign_event.document.failed_to_load
                            - sign_event.document.downloaded
                            - sign_event.error.reset
                            - email_event.agreement_invitation.delivery_failed
                            - email_event.agreement_invitation.delivered
                            - email_event.agreement_invitation.all_delivered
                            - email_event.agreement_observer_invitation.delivery_failed
                            - email_event.agreement_observer_invitation.delivered
                            - email_event.agreement_observer_invitation.all_delivered
                            - email_event.agreement_reminder.delivery_failed
                            - email_event.agreement_reminder.delivered
                            - email_event.agreement_reminder.all_delivered
                            - email_event.agreement_forwarded.delivery_failed
                            - email_event.agreement_forwarded.delivered
                            - email_event.agreement_forwarded.all_delivered
                            - email_event.agreement_finalized.delivery_failed
                            - email_event.agreement_finalized.delivered
                            - email_event.agreement_finalized.all_delivered
                            - email_event.agreement_cancelled.delivery_failed
                            - email_event.agreement_cancelled.delivered
                            - email_event.agreement_cancelled.all_delivered
                            - email_event.agreement_paused.delivery_failed
                            - email_event.agreement_paused.delivered
                            - email_event.agreement_paused.all_delivered
                            - observer.draft.created
                            - observer.draft.updated
                        description: The events that the webhook is subscribed to.
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - url
                      - secret
                      - type
                      - scope
                      - status
                      - subscriptions
                      - created_at
                      - updated_at
                    description: The resource data that was deleted.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: DELETE /webhooks/:webhook_id Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Deletes a webhook created for the account associated with the
        authenticated client.
      summary: Delete a Webhook
      tags:
        - Webhooks
      parameters:
        - name: webhook_id
          in: path
          required: true
          description: DELETE /webhooks/:webhook_id parameter
          schema:
            type: string
            format: cuid
            example: cwhdnmrffxpscuktjjgexample
      security:
        - HTTP_1: []
    put:
      operationId: PutWebhooksWebhookId
      responses:
        "200":
          description: PUT /webhooks/:webhook_id Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the webhook resource.
                  resource_type:
                    type: string
                    enum:
                      - webhook
                    description: Data contains the webhook resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the webhook endpoint
                        example: cxsbn6hqi1olfgumooyexample
                      name:
                        type: string
                        description: The name of the webhook. This is only used to help you identify the
                          webhook.
                        example: My webhook endpoint
                      resource_type:
                        type: string
                        enum:
                          - webhook
                      url:
                        type: string
                        format: url
                        description: The URL of the webhook endpoint. Must be HTTPS.
                        example: https://www.example.com
                      secret:
                        type: string
                        description: The webhook secret. This is used tfor the HMAC signature of the
                          webhook request, which is included in a header called
                          x-zigned-request-signature
                      type:
                        type: string
                        enum:
                          - production
                          - development
                        description: The type of the webhook endpoint. Development webhooks will only
                          receive events from agreements with test_mode set to
                          true.
                      scope:
                        discriminator:
                          propertyName: type
                        oneOf:
                          - type: object
                            properties:
                              type:
                                type: string
                                enum:
                                  - user
                              user_id:
                                type: string
                                format: cuid
                                description: The unique identifier of the user
                                example: csnmyjyztt2z356qdyaexample
                            required:
                              - type
                              - user_id
                          - type: object
                            properties:
                              type:
                                type: string
                                enum:
                                  - global
                            required:
                              - type
                        description: The scope of the webhook notifications. If set to user, only events
                          related to the agreements created by the scoped user
                          will be sent. If set to global, all events will be
                          sent.
                      status:
                        type: string
                        enum:
                          - active
                          - inactive
                        description: The status of the webhook. Only active webhooks will receive
                          notifications.
                      subscriptions:
                        type: array
                        items:
                          type: string
                          enum:
                            - agreement.draft.created
                            - agreement.draft.updated
                            - agreement.lifecycle.pending
                            - agreement.lifecycle.fulfilled
                            - agreement.lifecycle.finalized
                            - agreement.lifecycle.cancelled
                            - agreement.lifecycle.opened
                            - agreement.lifecycle.expired
                            - agreement.validation.started
                            - agreement.validation.completed
                            - agreement.validation.failed
                            - agreement.generation.restarted
                            - agreement.generation.started
                            - agreement.generation.completed
                            - agreement.generation.failed
                            - agreement.audit_trail_verification.started
                            - agreement.audit_trail_verification.completed
                            - agreement.audit_trail_verification.failed
                            - agreement.pdf_verification.started
                            - agreement.pdf_verification.completed
                            - agreement.pdf_verification.failed
                            - agreement.deletion.scheduled
                            - agreement.deletion.cancelled
                            - agreement.deletion.completed
                            - participant.draft.created
                            - participant.draft.updated
                            - participant.identity_enforcement.passed
                            - participant.identity_enforcement.failed
                            - participant.lifecycle.received_invitation
                            - participant.lifecycle.fulfilled
                            - participant.lifecycle.forwarded
                            - sign_event.signing_room.entered
                            - sign_event.signing_room.left
                            - sign_event.sign.initiated_sign
                            - sign_event.sign.cancelled_sign
                            - sign_event.sign.completed_sign
                            - sign_event.sign.requested_otp
                            - sign_event.sign.received_otp
                            - sign_event.sign.failed_to_receive_otp
                            - sign_event.sign.confirm_otp_failed
                            - sign_event.sign.confirmed_otp
                            - sign_event.sign.changed_email_for_otp
                            - sign_event.sign.forwarded_link
                            - sign_event.approval.approved
                            - sign_event.approval.disapproved
                            - sign_event.document.began_scroll
                            - sign_event.document.scrolled_to_bottom
                            - sign_event.document.clicked_to_view
                            - sign_event.document.loaded
                            - sign_event.document.failed_to_load
                            - sign_event.document.downloaded
                            - sign_event.error.reset
                            - email_event.agreement_invitation.delivery_failed
                            - email_event.agreement_invitation.delivered
                            - email_event.agreement_invitation.all_delivered
                            - email_event.agreement_observer_invitation.delivery_failed
                            - email_event.agreement_observer_invitation.delivered
                            - email_event.agreement_observer_invitation.all_delivered
                            - email_event.agreement_reminder.delivery_failed
                            - email_event.agreement_reminder.delivered
                            - email_event.agreement_reminder.all_delivered
                            - email_event.agreement_forwarded.delivery_failed
                            - email_event.agreement_forwarded.delivered
                            - email_event.agreement_forwarded.all_delivered
                            - email_event.agreement_finalized.delivery_failed
                            - email_event.agreement_finalized.delivered
                            - email_event.agreement_finalized.all_delivered
                            - email_event.agreement_cancelled.delivery_failed
                            - email_event.agreement_cancelled.delivered
                            - email_event.agreement_cancelled.all_delivered
                            - email_event.agreement_paused.delivery_failed
                            - email_event.agreement_paused.delivered
                            - email_event.agreement_paused.all_delivered
                            - observer.draft.created
                            - observer.draft.updated
                        description: The events that the webhook is subscribed to.
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - url
                      - secret
                      - type
                      - scope
                      - status
                      - subscriptions
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: PUT /webhooks/:webhook_id Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Updates a webhook created by the account associated with the
        authenticated client.
      summary: Update a Webhook
      parameters:
        - name: webhook_id
          in: path
          required: true
          description: PUT /webhooks/:webhook_id parameter
          schema:
            type: string
            format: cuid
            example: c6zdeqsg17i76udsybvexample
      requestBody:
        description: PUT /webhooks/:webhook_id request body
        content:
          application/json:
            schema:
              allOf:
                - allOf:
                    - allOf:
                        - type: object
                          properties: {}
                        - type: object
                          properties: {}
                    - type: object
                      properties: {}
                - type: object
                  properties:
                    url:
                      type: string
                      format: url
                      description: The URL which will receive the webhook notifications. Must be
                        HTTPS.
                      example: https://www.example.com
                    name:
                      type: string
                      description: The name of the webhook. The name is only to help you identify the
                        webhook in responses.
                      example: My webhook
                    type:
                      type: string
                      enum:
                        - production
                        - development
                      description: The type of the webhook. If set to development, the webhooks will
                        only be notified of agreements with test_mode set to
                        true.
                    status:
                      type: string
                      enum:
                        - active
                        - inactive
                      description: The status of the webhook. Only active webhooks receive
                        notifications.
                    scope:
                      type: string
                      enum:
                        - global
                        - user
                        - client
                      description: The scope of the webhook. If set to global, the webhook will be
                        notified of all events for all agreements. If set to
                        user, the webhook will only be notified of agreements
                        created by the your account.
                    subscriptions:
                      type: array
                      items:
                        oneOf:
                          - type: object
                            properties:
                              event:
                                type: string
                                enum:
                                  - agreement.draft.created
                                  - agreement.draft.updated
                                  - agreement.lifecycle.pending
                                  - agreement.lifecycle.fulfilled
                                  - agreement.lifecycle.finalized
                                  - agreement.lifecycle.cancelled
                                  - agreement.lifecycle.opened
                                  - agreement.lifecycle.expired
                                  - agreement.validation.started
                                  - agreement.validation.completed
                                  - agreement.validation.failed
                                  - agreement.generation.restarted
                                  - agreement.generation.started
                                  - agreement.generation.completed
                                  - agreement.generation.failed
                                  - agreement.audit_trail_verification.started
                                  - agreement.audit_trail_verification.completed
                                  - agreement.audit_trail_verification.failed
                                  - agreement.pdf_verification.started
                                  - agreement.pdf_verification.completed
                                  - agreement.pdf_verification.failed
                                  - agreement.deletion.scheduled
                                  - agreement.deletion.cancelled
                                  - agreement.deletion.completed
                                  - participant.draft.created
                                  - participant.draft.updated
                                  - participant.identity_enforcement.passed
                                  - participant.identity_enforcement.failed
                                  - participant.lifecycle.received_invitation
                                  - participant.lifecycle.fulfilled
                                  - participant.lifecycle.forwarded
                                  - sign_event.signing_room.entered
                                  - sign_event.signing_room.left
                                  - sign_event.sign.initiated_sign
                                  - sign_event.sign.cancelled_sign
                                  - sign_event.sign.completed_sign
                                  - sign_event.sign.requested_otp
                                  - sign_event.sign.received_otp
                                  - sign_event.sign.failed_to_receive_otp
                                  - sign_event.sign.confirm_otp_failed
                                  - sign_event.sign.confirmed_otp
                                  - sign_event.sign.changed_email_for_otp
                                  - sign_event.sign.forwarded_link
                                  - sign_event.approval.approved
                                  - sign_event.approval.disapproved
                                  - sign_event.document.began_scroll
                                  - sign_event.document.scrolled_to_bottom
                                  - sign_event.document.clicked_to_view
                                  - sign_event.document.loaded
                                  - sign_event.document.failed_to_load
                                  - sign_event.document.downloaded
                                  - sign_event.error.reset
                                  - email_event.agreement_invitation.delivery_failed
                                  - email_event.agreement_invitation.delivered
                                  - email_event.agreement_invitation.all_delivered
                                  - email_event.agreement_observer_invitation.delivery_failed
                                  - email_event.agreement_observer_invitation.delivered
                                  - email_event.agreement_observer_invitation.all_delivered
                                  - email_event.agreement_reminder.delivery_failed
                                  - email_event.agreement_reminder.delivered
                                  - email_event.agreement_reminder.all_delivered
                                  - email_event.agreement_forwarded.delivery_failed
                                  - email_event.agreement_forwarded.delivered
                                  - email_event.agreement_forwarded.all_delivered
                                  - email_event.agreement_finalized.delivery_failed
                                  - email_event.agreement_finalized.delivered
                                  - email_event.agreement_finalized.all_delivered
                                  - email_event.agreement_cancelled.delivery_failed
                                  - email_event.agreement_cancelled.delivered
                                  - email_event.agreement_cancelled.all_delivered
                                  - email_event.agreement_paused.delivery_failed
                                  - email_event.agreement_paused.delivered
                                  - email_event.agreement_paused.all_delivered
                                  - observer.draft.created
                                  - observer.draft.updated
                            required:
                              - event
                          - type: object
                            properties:
                              event:
                                type: string
                                enum:
                                  - agreement.draft.created
                                  - agreement.draft.updated
                                  - agreement.lifecycle.pending
                                  - agreement.lifecycle.fulfilled
                                  - agreement.lifecycle.finalized
                                  - agreement.lifecycle.cancelled
                                  - agreement.lifecycle.opened
                                  - agreement.lifecycle.expired
                                  - agreement.validation.started
                                  - agreement.validation.completed
                                  - agreement.validation.failed
                                  - agreement.generation.restarted
                                  - agreement.generation.started
                                  - agreement.generation.completed
                                  - agreement.generation.failed
                                  - agreement.audit_trail_verification.started
                                  - agreement.audit_trail_verification.completed
                                  - agreement.audit_trail_verification.failed
                                  - agreement.pdf_verification.started
                                  - agreement.pdf_verification.completed
                                  - agreement.pdf_verification.failed
                                  - agreement.deletion.scheduled
                                  - agreement.deletion.cancelled
                                  - agreement.deletion.completed
                                  - participant.draft.created
                                  - participant.draft.updated
                                  - participant.identity_enforcement.passed
                                  - participant.identity_enforcement.failed
                                  - participant.lifecycle.received_invitation
                                  - participant.lifecycle.fulfilled
                                  - participant.lifecycle.forwarded
                                  - sign_event.signing_room.entered
                                  - sign_event.signing_room.left
                                  - sign_event.sign.initiated_sign
                                  - sign_event.sign.cancelled_sign
                                  - sign_event.sign.completed_sign
                                  - sign_event.sign.requested_otp
                                  - sign_event.sign.received_otp
                                  - sign_event.sign.failed_to_receive_otp
                                  - sign_event.sign.confirm_otp_failed
                                  - sign_event.sign.confirmed_otp
                                  - sign_event.sign.changed_email_for_otp
                                  - sign_event.sign.forwarded_link
                                  - sign_event.approval.approved
                                  - sign_event.approval.disapproved
                                  - sign_event.document.began_scroll
                                  - sign_event.document.scrolled_to_bottom
                                  - sign_event.document.clicked_to_view
                                  - sign_event.document.loaded
                                  - sign_event.document.failed_to_load
                                  - sign_event.document.downloaded
                                  - sign_event.error.reset
                                  - email_event.agreement_invitation.delivery_failed
                                  - email_event.agreement_invitation.delivered
                                  - email_event.agreement_invitation.all_delivered
                                  - email_event.agreement_observer_invitation.delivery_failed
                                  - email_event.agreement_observer_invitation.delivered
                                  - email_event.agreement_observer_invitation.all_delivered
                                  - email_event.agreement_reminder.delivery_failed
                                  - email_event.agreement_reminder.delivered
                                  - email_event.agreement_reminder.all_delivered
                                  - email_event.agreement_forwarded.delivery_failed
                                  - email_event.agreement_forwarded.delivered
                                  - email_event.agreement_forwarded.all_delivered
                                  - email_event.agreement_finalized.delivery_failed
                                  - email_event.agreement_finalized.delivered
                                  - email_event.agreement_finalized.all_delivered
                                  - email_event.agreement_cancelled.delivery_failed
                                  - email_event.agreement_cancelled.delivered
                                  - email_event.agreement_cancelled.all_delivered
                                  - email_event.agreement_paused.delivery_failed
                                  - email_event.agreement_paused.delivered
                                  - email_event.agreement_paused.all_delivered
                                  - observer.draft.created
                                  - observer.draft.updated
                              unsubscribe:
                                type: boolean
                                enum:
                                  - true
                            required:
                              - event
                              - unsubscribe
                      default: []
                      description: The events to subscribe to or unsubscribe from. To unsubscribe, set
                        unsubscribe to true.
                  required: []
      security:
        - HTTP_1: []
    get:
      operationId: GetWebhooksWebhookId
      responses:
        "200":
          description: GET /webhooks/:webhook_id Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the webhook resource.
                  resource_type:
                    type: string
                    enum:
                      - webhook
                    description: Data contains the webhook resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the webhook endpoint
                        example: cxsbn6hqi1olfgumooyexample
                      name:
                        type: string
                        description: The name of the webhook. This is only used to help you identify the
                          webhook.
                        example: My webhook endpoint
                      resource_type:
                        type: string
                        enum:
                          - webhook
                      url:
                        type: string
                        format: url
                        description: The URL of the webhook endpoint. Must be HTTPS.
                        example: https://www.example.com
                      secret:
                        type: string
                        description: The webhook secret. This is used tfor the HMAC signature of the
                          webhook request, which is included in a header called
                          x-zigned-request-signature
                      type:
                        type: string
                        enum:
                          - production
                          - development
                        description: The type of the webhook endpoint. Development webhooks will only
                          receive events from agreements with test_mode set to
                          true.
                      scope:
                        discriminator:
                          propertyName: type
                        oneOf:
                          - type: object
                            properties:
                              type:
                                type: string
                                enum:
                                  - user
                              user_id:
                                type: string
                                format: cuid
                                description: The unique identifier of the user
                                example: csnmyjyztt2z356qdyaexample
                            required:
                              - type
                              - user_id
                          - type: object
                            properties:
                              type:
                                type: string
                                enum:
                                  - global
                            required:
                              - type
                        description: The scope of the webhook notifications. If set to user, only events
                          related to the agreements created by the scoped user
                          will be sent. If set to global, all events will be
                          sent.
                      status:
                        type: string
                        enum:
                          - active
                          - inactive
                        description: The status of the webhook. Only active webhooks will receive
                          notifications.
                      subscriptions:
                        type: array
                        items:
                          type: string
                          enum:
                            - agreement.draft.created
                            - agreement.draft.updated
                            - agreement.lifecycle.pending
                            - agreement.lifecycle.fulfilled
                            - agreement.lifecycle.finalized
                            - agreement.lifecycle.cancelled
                            - agreement.lifecycle.opened
                            - agreement.lifecycle.expired
                            - agreement.validation.started
                            - agreement.validation.completed
                            - agreement.validation.failed
                            - agreement.generation.restarted
                            - agreement.generation.started
                            - agreement.generation.completed
                            - agreement.generation.failed
                            - agreement.audit_trail_verification.started
                            - agreement.audit_trail_verification.completed
                            - agreement.audit_trail_verification.failed
                            - agreement.pdf_verification.started
                            - agreement.pdf_verification.completed
                            - agreement.pdf_verification.failed
                            - agreement.deletion.scheduled
                            - agreement.deletion.cancelled
                            - agreement.deletion.completed
                            - participant.draft.created
                            - participant.draft.updated
                            - participant.identity_enforcement.passed
                            - participant.identity_enforcement.failed
                            - participant.lifecycle.received_invitation
                            - participant.lifecycle.fulfilled
                            - participant.lifecycle.forwarded
                            - sign_event.signing_room.entered
                            - sign_event.signing_room.left
                            - sign_event.sign.initiated_sign
                            - sign_event.sign.cancelled_sign
                            - sign_event.sign.completed_sign
                            - sign_event.sign.requested_otp
                            - sign_event.sign.received_otp
                            - sign_event.sign.failed_to_receive_otp
                            - sign_event.sign.confirm_otp_failed
                            - sign_event.sign.confirmed_otp
                            - sign_event.sign.changed_email_for_otp
                            - sign_event.sign.forwarded_link
                            - sign_event.approval.approved
                            - sign_event.approval.disapproved
                            - sign_event.document.began_scroll
                            - sign_event.document.scrolled_to_bottom
                            - sign_event.document.clicked_to_view
                            - sign_event.document.loaded
                            - sign_event.document.failed_to_load
                            - sign_event.document.downloaded
                            - sign_event.error.reset
                            - email_event.agreement_invitation.delivery_failed
                            - email_event.agreement_invitation.delivered
                            - email_event.agreement_invitation.all_delivered
                            - email_event.agreement_observer_invitation.delivery_failed
                            - email_event.agreement_observer_invitation.delivered
                            - email_event.agreement_observer_invitation.all_delivered
                            - email_event.agreement_reminder.delivery_failed
                            - email_event.agreement_reminder.delivered
                            - email_event.agreement_reminder.all_delivered
                            - email_event.agreement_forwarded.delivery_failed
                            - email_event.agreement_forwarded.delivered
                            - email_event.agreement_forwarded.all_delivered
                            - email_event.agreement_finalized.delivery_failed
                            - email_event.agreement_finalized.delivered
                            - email_event.agreement_finalized.all_delivered
                            - email_event.agreement_cancelled.delivery_failed
                            - email_event.agreement_cancelled.delivered
                            - email_event.agreement_cancelled.all_delivered
                            - email_event.agreement_paused.delivery_failed
                            - email_event.agreement_paused.delivered
                            - email_event.agreement_paused.all_delivered
                            - observer.draft.created
                            - observer.draft.updated
                        description: The events that the webhook is subscribed to.
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - url
                      - secret
                      - type
                      - scope
                      - status
                      - subscriptions
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
        "400":
          description: GET /webhooks/:webhook_id Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        format: int64
                        minimum: 400
                        exclusiveMinimum: false
                        maximum: 599
                        exclusiveMaximum: false
                      message:
                        type: string
                      request_id:
                        type: string
                        format: uuid
                    required:
                      - code
                      - message
                      - request_id
                required:
                  - status
                  - error
      description: Retrieves a webhook created by the account associated with the
        authenticated client.
      summary: Retrieve a Webhook
      parameters:
        - name: webhook_id
          in: path
          required: true
          description: GET /webhooks/:webhook_id parameter
          schema:
            type: string
            format: cuid
            example: cw3rsimcuwkvueunopdexample
      security:
        - HTTP_1: []
components:
  schemas:
    95c1af3f45da65daeedb661f70210b46b2bd71d5:
      type: array
      items:
        allOf:
          - type: object
            properties:
              id:
                type: string
                format: cuid
                description: The unique identifier of the participant
                example: c7uwzf2hygix6pmzsh5example
              resource_type:
                type: string
                enum:
                  - participant
              name:
                nullable: true
                type: string
                description: The name of the participant. Required if no email is provided.
                example: Jane Doe
              email:
                nullable: true
                type: string
                description: The email of the participant. Required if agreemnt is configured to
                  send emails.
                example: jane.doe@example.com
              status:
                type: string
                enum:
                  - draft
                  - pending
                  - initiated
                  - processing
                  - fulfilled
                  - rejected
                description: The status of the participant
              order:
                nullable: true
                type: number
                format: double
                minimum: 0
                exclusiveMinimum: true
                maximum: 1.7976931348623157e+308
                exclusiveMaximum: false
                description: The queue number of the participant (if sequential signing order is
                  enabled)
                example: 1
              signing_group:
                oneOf:
                  - type: string
                    format: cuid
                    description: The unique identifier for the signing groups
                    example: cgbzlzelirbjrjq0xrxexample
                  - $ref: "#/components/schemas/118cb3b11b8a1f3b6b1e60a89f96a8be9da32a0f"
                  - type: string
                    nullable: true
                    format: "null"
              agreement:
                type: string
                format: cuid
                description: The unique identifier for the agreement this participant belongs to
                example: cj2orx6w6iqpscuqsieexample
              signing_room_url:
                nullable: true
                type: string
                format: url
                example: https://www.zigned.se/sign/cjecfacxrxzqd9def5zexample/cmakdfl6yfb9ls8h6jyexample
                description: The URL to the signing room for the participant. Only available
                  after the agreement has been finalized for signing.
              locale:
                nullable: true
                type: string
                enum:
                  - sv-SE
                  - en-US
                description: The locale for the participant. Can be overridden from the signing
                  room, but this value serves as the default if nothing else is
                  specified.
              created_at:
                type: string
                description: UTC datetime ISO string
                example: 2024-01-01T00:00:00.000Z
              updated_at:
                type: string
                description: UTC datetime ISO string
                example: 2024-01-01T00:00:00.000Z
            required:
              - id
              - resource_type
              - name
              - email
              - status
              - order
              - signing_group
              - agreement
              - signing_room_url
              - created_at
              - updated_at
            description: The participant resource
          - discriminator:
              propertyName: role
            oneOf:
              - type: object
                properties:
                  role:
                    type: string
                    enum:
                      - approver
                    description: The role of the participant
                  decision_made_at:
                    nullable: true
                    type: string
                    description: UTC datetime ISO string
                    example: 2024-01-01T00:00:00.000Z
                required:
                  - role
                  - decision_made_at
              - type: object
                properties:
                  role:
                    type: string
                    enum:
                      - signer
                    description: The role of the participant
                  signed_at:
                    nullable: true
                    type: string
                    description: UTC datetime ISO string
                    example: 2024-01-01T00:00:00.000Z
                  signature:
                    nullable: true
                    oneOf:
                      - allOf:
                          - type: object
                            properties:
                              id:
                                type: string
                                format: cuid
                                description: The unique identifier of the signature data
                                example: cqdax9rdsuqyvtgemlzexample
                              created_at:
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                              updated_at:
                                type: string
                                description: UTC datetime ISO string
                                example: 2024-01-01T00:00:00.000Z
                            required:
                              - id
                              - created_at
                              - updated_at
                          - discriminator:
                              propertyName: method
                            oneOf:
                              - type: object
                                properties:
                                  method:
                                    type: string
                                    enum:
                                      - se_bid
                                    description: The method used for signing
                                  data:
                                    type: object
                                    properties:
                                      name:
                                        nullable: true
                                        type: string
                                        description: The full name of the signer returned by Mobile Swedish BankID
                                        example: Jane Doe
                                      user_message:
                                        type: string
                                        description: The message presented to the user in the Mobile BankID application
                                          when signing
                                        example: I have read and understood the contents of the document example.pdf and
                                          I hereby approve everything in it.
                                      document_hash:
                                        type: string
                                        description: The SHA256 hash of the document to be signed (Base64 encoded)
                                        example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                      status:
                                        type: string
                                        enum:
                                          - complete
                                          - error
                                          - failed
                                          - draft
                                          - pending
                                          - initializing
                                          - cancelled
                                        description: The status for the Swedish BankID signing process
                                    required:
                                      - name
                                      - user_message
                                      - document_hash
                                      - status
                                    description: Summary of the BankID signature data
                                required:
                                  - method
                                  - data
                              - type: object
                                properties:
                                  method:
                                    type: string
                                    enum:
                                      - verification_code
                                    description: The method used for signing
                                  data:
                                    type: object
                                    properties:
                                      email:
                                        nullable: true
                                        type: string
                                        description: The email used for the verification code
                                        example: john.doe@example.com
                                      name:
                                        nullable: true
                                        type: string
                                        description: The name of the signer
                                        example: John Doe
                                      user_message:
                                        type: string
                                        description: The message presented to the user when signing
                                        example: I have read and understood the contents of the document example.pdf and
                                          I hereby approve everything in it.
                                      document_hash:
                                        type: string
                                        description: The SHA256 hash of the document to be signed (Base64 encoded)
                                        example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                      status:
                                        type: string
                                        enum:
                                          - confirmed
                                          - draft
                                          - pending
                                          - confirmation_failed
                                          - unable_to_send
                                          - expired
                                          - cancelled
                                        description: The status of the verification code signing process
                                    required:
                                      - email
                                      - name
                                      - user_message
                                      - document_hash
                                      - status
                                    description: Summary of the verification code signature data
                                required:
                                  - method
                                  - data
                              - type: object
                                properties:
                                  method:
                                    type: string
                                    enum:
                                      - truid
                                    description: The method used for signing
                                  data:
                                    type: object
                                    properties:
                                      given_name:
                                        nullable: true
                                        type: string
                                        description: The given name of the signer returned by Truid
                                        example: Jane
                                      family_name:
                                        nullable: true
                                        type: string
                                        description: The family name of the signer returned by Truid
                                        example: Doe
                                      legal_name:
                                        nullable: true
                                        type: string
                                        description: The legal name of the signer returned by Truid
                                        example: Jane Doe
                                      user_message:
                                        type: string
                                        description: The message presented to the user in the Truid application when
                                          signing
                                        example: I have read and wish to sign the document.
                                      document_hash:
                                        type: string
                                        description: The SHA256 hash of the document to be signed (Base64 encoded)
                                        example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                      status:
                                        type: string
                                        enum:
                                          - draft
                                          - pending
                                          - fulfilled
                                          - failed
                                        description: The status for the Truid signing process
                                    required:
                                      - given_name
                                      - family_name
                                      - legal_name
                                      - user_message
                                      - document_hash
                                      - status
                                    description: Summary of the Truid signature data
                                required:
                                  - method
                                  - data
                              - type: object
                                properties:
                                  method:
                                    type: string
                                    enum:
                                      - zealid
                                    description: The method used for signing
                                  data:
                                    type: object
                                    properties:
                                      givenname:
                                        nullable: true
                                        type: string
                                        description: The given name of the signer as specified in the signing
                                          certificate
                                        example: Jane
                                      surname:
                                        nullable: true
                                        type: string
                                        description: The surname of the signer as specified in the signing certificate
                                        example: Doe
                                      country:
                                        nullable: true
                                        type: string
                                        description: The country of the signer as specified in the signing certificate
                                        example: SE
                                      identifier:
                                        nullable: true
                                        type: string
                                        description: The primary identifier, such as a Swedish Personal Number, as
                                          specified in the signing certificate
                                        example: SE
                                      signing_certificate:
                                        nullable: true
                                        type: string
                                        description: The signing certificate for the signatory, returned by ZealID
                                        example: |-
                                          --BEGIN CERTIFICATE--
                                          [BASE64 ENCODED CERTIFICATE]
                                          --END CERTIFICATE--
                                      document_hash:
                                        type: string
                                        description: The SHA256 hash of the data to be signed (Base64 encoded)
                                        example: XTxXzdboxtCjFJAPMZZpsqiQfm8ZqOz00Kq2fRktAyo=
                                      status:
                                        type: string
                                        enum:
                                          - draft
                                          - awaiting_authentication
                                          - awaiting_sign
                                          - complete
                                          - failed
                                        description: The status for the ZealID signing process
                                    required:
                                      - givenname
                                      - surname
                                      - country
                                      - identifier
                                      - signing_certificate
                                      - document_hash
                                      - status
                                    description: Summary of the ZealID signature data
                                required:
                                  - method
                                  - data
                      - type: object
                        properties:
                          method:
                            type: string
                            nullable: true
                            format: "null"
                          data:
                            type: string
                            nullable: true
                            format: "null"
                        required:
                          - method
                          - data
                    description: The signature data for the participant
                  identity_enforcement:
                    discriminator:
                      propertyName: enabled
                    oneOf:
                      - type: object
                        properties:
                          enabled:
                            type: boolean
                            enum:
                              - true
                            description: If true, identity enforcement is enabled for the participant
                          status:
                            type: string
                            enum:
                              - pending
                              - passed
                              - failed
                            description: The status of the identity enforcement
                          enforcement_method:
                            type: string
                            enum:
                              - swe_pno_crosscheck
                            description: The enforcement method for the identity. Depending on which method
                              is used, different signature method are available
                        required:
                          - enabled
                          - status
                          - enforcement_method
                      - type: object
                        properties:
                          enabled:
                            type: boolean
                            enum:
                              - false
                            description: If true, identity enforcement is enabled for the participant
                          status:
                            type: string
                            nullable: true
                            format: "null"
                          enforcement_method:
                            type: string
                            nullable: true
                            format: "null"
                        required:
                          - enabled
                          - status
                          - enforcement_method
                required:
                  - role
                  - signed_at
                  - signature
                  - identity_enforcement
    118cb3b11b8a1f3b6b1e60a89f96a8be9da32a0f:
      type: object
      properties:
        version:
          type: string
          enum:
            - "1.0"
          description: The version of the response schema
        result_type:
          type: string
          enum:
            - single
          description: A single object of the signing_group resource.
        resource_type:
          type: string
          enum:
            - signing_group
          description: Data contains the signing_group resource.
        data:
          type: object
          properties:
            id:
              type: string
              format: cuid
              description: The unique identifier of the signing group
              example: cwpgsuuwu3wwysvhghwexample
            resource_type:
              type: string
              enum:
                - signing_group
            name:
              type: string
              description: The name of the signing group
              example: Board Members
            status:
              type: string
              enum:
                - draft
                - pending
                - fulfilled
              description: The status of the signing group
            order:
              type: number
              format: double
              minimum: 5e-324
              exclusiveMinimum: false
              maximum: 1.7976931348623157e+308
              exclusiveMaximum: false
              description: The queue number of the signing group
              example: 1
            participants:
              oneOf:
                - type: array
                  items:
                    type: string
                    format: cuid
                    minLength: 1
                  description: List of IDs for the participants belonging to the signing group
                  example:
                    - c5lnvzb9saw7pkusnvcexample
                    - cgizx0nvpnyzxupx0cvexample
                    - codqlu3eiigxia664m3example
                - $ref: "#/components/schemas/118cb3b11b8a1f3b6b1e60a89f96a8be9da32a0f"
                - type: string
                  nullable: true
                  format: "null"
            agreement:
              type: string
              format: cuid
              description: The unique identifier of the agreement this signing group belongs
                to
              example: cqah6osvogc9vpeai9dexample
            created_at:
              type: string
              description: UTC datetime ISO string
              example: 2024-01-01T00:00:00.000Z
            updated_at:
              type: string
              description: UTC datetime ISO string
              example: 2024-01-01T00:00:00.000Z
          required:
            - id
            - resource_type
            - name
            - status
            - order
            - participants
            - agreement
            - created_at
            - updated_at
          description: The resource data.
      required:
        - version
        - result_type
        - resource_type
        - data
    c893c5c1d97a5bcbd8972ce188f48f8f75c6a171:
      type: array
      items:
        type: object
        properties:
          id:
            type: string
            format: cuid
            description: The unique identifier of the observer
            example: cmxm8kdqkf9bxoalwinexample
          resource_type:
            type: string
            enum:
              - observer
          name:
            nullable: true
            type: string
            description: The name of the observer. Required if no email is provided.
            example: Jane Doe
          email:
            nullable: true
            type: string
            description: The email of the observer. Required if agreement is configured to
              send emails or if the observer_scope is 'cc'.
            example: jane.doe@example.com
          locale:
            nullable: true
            type: string
            enum:
              - sv-SE
              - en-US
            description: The locale for the observer. Can be overridden from the signing
              room (if the observer_scope is 'viewer'), but this value serves as
              the default if nothing else is specified.
          observer_scope:
            type: string
            enum:
              - cc
              - viewer
            description: The scope of the observer. If specified as viewer, they will gain
              access to the signing room to follow the process. Otherwise, they
              will only receive the final, signed document.
          agreement:
            type: string
            format: cuid
            description: The unique identifier for the agreement this observer belongs to
            example: cp9tppmeltnhqeckzz3example
          signing_room_url:
            nullable: true
            type: string
            format: url
            example: https://www.zigned.se/sign/cjecfacxrxzqd9def5zexample/cmakdfl6yfb9ls8h6jyexample
            description: The URL to the signing room for the observer. Only available after
              the agreement is not in draft.
          created_at:
            type: string
            description: UTC datetime ISO string
            example: 2024-01-01T00:00:00.000Z
          updated_at:
            type: string
            description: UTC datetime ISO string
            example: 2024-01-01T00:00:00.000Z
        required:
          - id
          - resource_type
          - name
          - email
          - observer_scope
          - agreement
          - signing_room_url
          - created_at
          - updated_at
        description: The observer resource
    d69cfbd1e408327b80080ee78c087563df3370f4:
      type: array
      items:
        type: object
        properties:
          id:
            type: string
            format: cuid
            description: The unique identifier of the signing group
            example: cwpgsuuwu3wwysvhghwexample
          resource_type:
            type: string
            enum:
              - signing_group
          name:
            type: string
            description: The name of the signing group
            example: Board Members
          status:
            type: string
            enum:
              - draft
              - pending
              - fulfilled
            description: The status of the signing group
          order:
            type: number
            format: double
            minimum: 5e-324
            exclusiveMinimum: false
            maximum: 1.7976931348623157e+308
            exclusiveMaximum: false
            description: The queue number of the signing group
            example: 1
          participants:
            oneOf:
              - type: array
                items:
                  type: string
                  format: cuid
                  minLength: 1
                description: List of IDs for the participants belonging to the signing group
                example:
                  - c5lnvzb9saw7pkusnvcexample
                  - cgizx0nvpnyzxupx0cvexample
                  - codqlu3eiigxia664m3example
              - $ref: "#/components/schemas/118cb3b11b8a1f3b6b1e60a89f96a8be9da32a0f"
              - type: string
                nullable: true
                format: "null"
          agreement:
            type: string
            format: cuid
            description: The unique identifier of the agreement this signing group belongs
              to
            example: cqah6osvogc9vpeai9dexample
          created_at:
            type: string
            description: UTC datetime ISO string
            example: 2024-01-01T00:00:00.000Z
          updated_at:
            type: string
            description: UTC datetime ISO string
            example: 2024-01-01T00:00:00.000Z
        required:
          - id
          - resource_type
          - name
          - status
          - order
          - participants
          - agreement
          - created_at
          - updated_at
        description: the signing group object
    18aea1f88c852890888d309ddd8605d8c0438d2b:
      type: array
      items:
        type: object
        properties:
          id:
            type: string
            format: cuid
            description: The unique identifier of the attachment
            example: cceyporub5ufunzbc3wexample
          resource_type:
            type: string
            enum:
              - attachment
          agreement:
            type: string
            format: cuid
            description: The unique identifier of the agreement which this attachment
              belongs to
            example: cljzatjzjjnjdsdzbf5example
          order:
            type: integer
            format: int64
            minimum: 0
            exclusiveMinimum: true
            maximum: 9007199254740991
            exclusiveMaximum: false
            description: The order of this attachment relative to the other attachments
            example: 1
          file:
            oneOf:
              - type: string
                format: cuid
                description: The unique identifier for the attached document
                example: ci3bkfyapgl4srrtji9example
              - type: object
                properties:
                  version:
                    type: string
                    enum:
                      - "1.0"
                    description: The version of the response schema
                  result_type:
                    type: string
                    enum:
                      - single
                    description: A single object of the file resource.
                  resource_type:
                    type: string
                    enum:
                      - file
                    description: Data contains the file resource.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: cuid
                        description: The unique identifier of the file
                        example: cytp5m6ijs4rxs0erqsexample
                      resource_type:
                        type: string
                        enum:
                          - file
                      filename:
                        type: string
                        minLength: 1
                        description: The complete filename including the file extension
                        example: my-file.pdf
                      mime_type:
                        type: string
                        minLength: 1
                        description: The mime type of the file
                        example: application/pdf
                      url:
                        type: string
                        format: url
                        description: The signed read url of the file
                        example: https://zigned.se
                      metadata:
                        type: object
                        properties:
                          lookup_key:
                            type: string
                            description: A provided lookup key provided by you to help you identify the
                              file.
                            example: file_tag
                        required:
                          - lookup_key
                      created_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                      updated_at:
                        type: string
                        description: UTC datetime ISO string
                        example: 2024-01-01T00:00:00.000Z
                    required:
                      - id
                      - resource_type
                      - filename
                      - mime_type
                      - created_at
                      - updated_at
                    description: The resource data.
                required:
                  - version
                  - result_type
                  - resource_type
                  - data
          created_at:
            type: string
            description: UTC datetime ISO string
            example: 2024-01-01T00:00:00.000Z
          updated_at:
            type: string
            description: UTC datetime ISO string
            example: 2024-01-01T00:00:00.000Z
        required:
          - id
          - resource_type
          - agreement
          - order
          - file
          - created_at
          - updated_at
        description: the attachment object
    7aadbd48657236af70d97541a9c85c00b14e95a5:
      type: array
      items:
        type: object
        properties:
          id:
            type: string
            format: cuid
            description: The unique identifier of the recipient message template
            example: cbffwj3f8wjic8dnnnyexample
          template_string:
            type: string
          resource_type:
            type: string
            enum:
              - recipient_message_template
          locale:
            type: string
            enum:
              - sv-SE
              - en-US
          created_at:
            type: string
            description: UTC datetime ISO string
            example: 2024-01-01T00:00:00.000Z
          updated_at:
            type: string
            description: UTC datetime ISO string
            example: 2024-01-01T00:00:00.000Z
        required:
          - id
          - template_string
          - resource_type
          - locale
          - created_at
          - updated_at
        description: The recipient message template resource
    f9a847cbdf0e167d1aa8d3b7127afb96d878e823:
      type: array
      items:
        type: object
        properties:
          id:
            type: string
            format: cuid
            description: The unique identifier of the recipient message variable
            example: cbm5u2qzzrdgnx6b3tzexample
          resource_type:
            type: string
            enum:
              - recipient_message_template_variable
          variable_name:
            type: string
          variable_value:
            type: string
          created_at:
            type: string
            description: UTC datetime ISO string
            example: 2024-01-01T00:00:00.000Z
          updated_at:
            type: string
            description: UTC datetime ISO string
            example: 2024-01-01T00:00:00.000Z
        required:
          - id
          - resource_type
          - variable_name
          - variable_value
          - created_at
          - updated_at
        description: The recipient message variable resource
    a3c0a57c88c3f5431a04cced7bd35e9fc77a12bb:
      type: array
      items:
        type: object
        properties:
          id:
            type: string
            format: cuid
            description: The unique identifier of the agreement event
            example: ccgepaxz5fyoks3ilmkexample
          resource_type:
            type: string
            enum:
              - agreement_event
          agreement:
            type: string
            format: cuid
            description: The unique identifier of the agreement which this event belongs to
            example: cwn3kw0qrbzqwpkhowzexample
          title:
            type: string
            minLength: 1
            description: The title of the agreement event
            example: Completed validation of participants
          description:
            type: string
            minLength: 1
            description: The description of the agreement event
            example: Completed validation of all participants
          created_at:
            type: string
            description: UTC datetime ISO string
            example: 2024-01-01T00:00:00.000Z
          updated_at:
            type: string
            description: UTC datetime ISO string
            example: 2024-01-01T00:00:00.000Z
        required:
          - id
          - resource_type
          - agreement
          - title
          - description
          - created_at
          - updated_at
        description: The agreement event object
    86d5051e0c6984da525697fc9654ac089e947844:
      type: array
      items:
        type: object
        properties:
          id:
            type: string
            format: cuid
            description: The unique identifier of the sign event
            example: cwrgj3ovp2uv81tnxxzexample
          resource_type:
            type: string
            enum:
              - sign_event
          title:
            type: string
            description: The title of the event
            example: Sign completed
          description:
            type: string
            description: The description of the event
            example: Completed signing of the documment with swedish mobile BankID.
          user_agent:
            type: string
            description: The user agent of the browser which triggered the event
            example: Mozilla/5.0 (Linux; Android 10; SM-G960F) AppleWebKit/537.36 (KHTML,
              like Gecko) Chrome/90.0.4430.210 Mobile Safari/537.36
          ip_address:
            type: string
            description: The IP address of the request which triggered the event
            example: 192.168.0.1
          participant:
            oneOf:
              - type: string
                format: cuid
                description: The unique identifier for the signed document
                example: cii3im3tolyo1d0nkryexample
              - $ref: "#/components/schemas/118cb3b11b8a1f3b6b1e60a89f96a8be9da32a0f"
              - type: string
                nullable: true
                format: "null"
          created_at:
            type: string
            description: UTC datetime ISO string
            example: 2024-01-01T00:00:00.000Z
          updated_at:
            type: string
            description: UTC datetime ISO string
            example: 2024-01-01T00:00:00.000Z
        required:
          - id
          - resource_type
          - title
          - description
          - user_agent
          - ip_address
          - participant
          - created_at
          - updated_at
        description: The sign event resource
    2048581c137c5b2130eb860e3ae37da196dfc25b:
      type: array
      items:
        type: object
        properties:
          id:
            type: string
            format: cuid
            description: The unique identifier of the webhook endpoint
            example: cxsbn6hqi1olfgumooyexample
          name:
            type: string
            description: The name of the webhook. This is only used to help you identify the
              webhook.
            example: My webhook endpoint
          resource_type:
            type: string
            enum:
              - webhook
          url:
            type: string
            format: url
            description: The URL of the webhook endpoint. Must be HTTPS.
            example: https://www.example.com
          secret:
            type: string
            description: The webhook secret. This is used tfor the HMAC signature of the
              webhook request, which is included in a header called
              x-zigned-request-signature
          type:
            type: string
            enum:
              - production
              - development
            description: The type of the webhook endpoint. Development webhooks will only
              receive events from agreements with test_mode set to true.
          scope:
            discriminator:
              propertyName: type
            oneOf:
              - type: object
                properties:
                  type:
                    type: string
                    enum:
                      - user
                  user_id:
                    type: string
                    format: cuid
                    description: The unique identifier of the user
                    example: csnmyjyztt2z356qdyaexample
                required:
                  - type
                  - user_id
              - type: object
                properties:
                  type:
                    type: string
                    enum:
                      - global
                required:
                  - type
            description: The scope of the webhook notifications. If set to user, only events
              related to the agreements created by the scoped user will be sent.
              If set to global, all events will be sent.
          status:
            type: string
            enum:
              - active
              - inactive
            description: The status of the webhook. Only active webhooks will receive
              notifications.
          subscriptions:
            type: array
            items:
              type: string
              enum:
                - agreement.draft.created
                - agreement.draft.updated
                - agreement.lifecycle.pending
                - agreement.lifecycle.fulfilled
                - agreement.lifecycle.finalized
                - agreement.lifecycle.cancelled
                - agreement.lifecycle.opened
                - agreement.lifecycle.expired
                - agreement.validation.started
                - agreement.validation.completed
                - agreement.validation.failed
                - agreement.generation.restarted
                - agreement.generation.started
                - agreement.generation.completed
                - agreement.generation.failed
                - agreement.audit_trail_verification.started
                - agreement.audit_trail_verification.completed
                - agreement.audit_trail_verification.failed
                - agreement.pdf_verification.started
                - agreement.pdf_verification.completed
                - agreement.pdf_verification.failed
                - agreement.deletion.scheduled
                - agreement.deletion.cancelled
                - agreement.deletion.completed
                - participant.draft.created
                - participant.draft.updated
                - participant.identity_enforcement.passed
                - participant.identity_enforcement.failed
                - participant.lifecycle.received_invitation
                - participant.lifecycle.fulfilled
                - participant.lifecycle.forwarded
                - sign_event.signing_room.entered
                - sign_event.signing_room.left
                - sign_event.sign.initiated_sign
                - sign_event.sign.cancelled_sign
                - sign_event.sign.completed_sign
                - sign_event.sign.requested_otp
                - sign_event.sign.received_otp
                - sign_event.sign.failed_to_receive_otp
                - sign_event.sign.confirm_otp_failed
                - sign_event.sign.confirmed_otp
                - sign_event.sign.changed_email_for_otp
                - sign_event.sign.forwarded_link
                - sign_event.approval.approved
                - sign_event.approval.disapproved
                - sign_event.document.began_scroll
                - sign_event.document.scrolled_to_bottom
                - sign_event.document.clicked_to_view
                - sign_event.document.loaded
                - sign_event.document.failed_to_load
                - sign_event.document.downloaded
                - sign_event.error.reset
                - email_event.agreement_invitation.delivery_failed
                - email_event.agreement_invitation.delivered
                - email_event.agreement_invitation.all_delivered
                - email_event.agreement_observer_invitation.delivery_failed
                - email_event.agreement_observer_invitation.delivered
                - email_event.agreement_observer_invitation.all_delivered
                - email_event.agreement_reminder.delivery_failed
                - email_event.agreement_reminder.delivered
                - email_event.agreement_reminder.all_delivered
                - email_event.agreement_forwarded.delivery_failed
                - email_event.agreement_forwarded.delivered
                - email_event.agreement_forwarded.all_delivered
                - email_event.agreement_finalized.delivery_failed
                - email_event.agreement_finalized.delivered
                - email_event.agreement_finalized.all_delivered
                - email_event.agreement_cancelled.delivery_failed
                - email_event.agreement_cancelled.delivered
                - email_event.agreement_cancelled.all_delivered
                - email_event.agreement_paused.delivery_failed
                - email_event.agreement_paused.delivered
                - email_event.agreement_paused.all_delivered
                - observer.draft.created
                - observer.draft.updated
            description: The events that the webhook is subscribed to.
          created_at:
            type: string
            description: UTC datetime ISO string
            example: 2024-01-01T00:00:00.000Z
          updated_at:
            type: string
            description: UTC datetime ISO string
            example: 2024-01-01T00:00:00.000Z
        required:
          - id
          - resource_type
          - url
          - secret
          - type
          - scope
          - status
          - subscriptions
          - created_at
          - updated_at
  responses: {}
  parameters: {}
  examples: {}
  requestBodies: {}
  headers: {}
  securitySchemes:
    HTTP_1:
      type: http
      scheme: bearer
  links: {}
  callbacks: {}
tags:
  - name: Webhooks
    description: Create, update and delete Webhooks
  - name: Signing Groups
    description: Create, update and delete signing groups of the agreement
  - name: Documents
    description: Create, update and delete documents of the agreement
  - name: Participants
    description: Create, update and delete participants of the agreement process
  - name: Agreements
    description: Create, update and delete agreements
  - name: Files
    description: Upload, update and delete files
  - name: Themes
    description: Create, update and delete themes
  - name: Recipient Messages
    description: Create, update and delete recipient messages
servers:
  - url: https://api.zigned.se/rest/v3
