{
  "openapi": "3.1.0",
  "info": {
    "version": "v0.8.9",
    "title": "Hovi API (Polygon)",
    "description": "The Hovi API integrates with the Polygon ecosystem, enabling the issuance and verification of JSON-LD Verifiable Credentials using the Iden3 protocol on the Polygon Amoy network. This documentation covers all API endpoints, streamlining the development of secure and scalable digital identity solutions."
  },
  "servers": [
    {
      "url": "https://api.hovi.id",
      "description": "Hovi SaaS"
    }
  ],
  "tags": [
    {
      "name": "Organization",
      "description": "Manages organizations (tenants) within Hovi — the primary actors that create credential templates, issue JSON-LD credentials, and initiate Iden3-based proof requests on the Polygon network."
    },
    {
      "name": "Webhooks",
      "description": "Configures asynchronous HTTP callbacks that Hovi POSTs to your server when events occur (e.g., credential issued, proof verified) — no polling required."
    },
    {
      "name": "Connections",
      "description": "Establishes and manages Iden3comm peer-to-peer channels between the organizational agent and holder wallets. Connections use the `iden3comm://` protocol and QR/URL-based invitation flows."
    },
    {
      "name": "Credential Templates",
      "description": "Defines the JSON-LD schema blueprint (fields, types, required flags) for a credential type. Templates generate IPFS-hosted schema context documents referenced during Iden3 credential issuance."
    },
    {
      "name": "Credentials",
      "description": "Issues JSON-LD Verifiable Credentials to holders via the Iden3 credential offer protocol. Holders claim credentials by scanning a QR code or deep link (`iden3comm://`) with a Polygon ID-compatible wallet."
    },
    {
      "name": "Verification Templates",
      "description": "Defines Polygon proof request blueprints using `privadoProofScopes` — Iden3 `credentialAtomicQuerySigV2` circuit conditions that specify which credential attributes and query operators the holder must satisfy."
    },
    {
      "name": "Verifications",
      "description": "Sends Iden3-based proof requests to holders and validates the submitted ZK proofs. Holders respond by scanning the `proofRequestUri` or `verificationUrl` with a Polygon ID-compatible wallet."
    },
    {
      "name": "Webhook Events",
      "description": "Asynchronous events delivered by Hovi to the callback URL registered for the organization."
    }
  ],
  "paths": {
    "/organization/create": {
      "post": {
        "tags": [
          "Organization"
        ],
        "summary": "Create Organization",
        "description": "This route allows for the creation of a new organization within an ecosystem.",
        "responses": {
          "201": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CreateTenantResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/CreateTenantResponse"
                }
              }
            }
          },
          "400": {
            "description": "Invalid params",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization creation limit exceeded. Please upgrade your plan or contact to support."
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization creation limit exceeded. Please upgrade your plan or contact to support."
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal Server Error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal Server Error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/createTenant"
              }
            },
            "application/xml": {
              "schema": {
                "$ref": "#/components/schemas/createTenant"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ]
      }
    },
    "/organization/": {
      "get": {
        "tags": [
          "Organization"
        ],
        "summary": "Get All Organization",
        "description": "Retrieves a list of organizations. By default, all organizations are returned.",
        "parameters": [
          {
            "name": "organizationId",
            "in": "query",
            "description": "Filters the result by a specific organization id.",
            "required": false,
            "example": "123e4567-e89b-12d3-a456-426614174000",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetTenantsResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/GetTenantsResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Unauthorized to access the organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Unauthorized to access the organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal Server Error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal Server Error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/organization/public-did": {
      "get": {
        "tags": [
          "Organization"
        ],
        "summary": "Get Public DID",
        "description": "This route retrieves the Decentralized Identifiers (DIDs) associated with a specific organization, identified by their organization id. The response includes a list of all DIDs linked to the organization, along with relevant metadata.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetTenantDidsResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/GetTenantDidsResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal Server Error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal Server Error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/organization/update": {
      "patch": {
        "tags": [
          "Organization"
        ],
        "summary": "Update Organization",
        "description": "This route allows for the modification of a organization’s metadata, such as their label and image URL. The organization is identified by their organization id.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/UpdateTenantResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/UpdateTenantResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal Server Error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal Server Error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/updateTenant"
              }
            },
            "application/xml": {
              "schema": {
                "$ref": "#/components/schemas/updateTenant"
              }
            }
          }
        }
      }
    },
    "/organization/rotate-key": {
      "post": {
        "tags": [
          "Organization"
        ],
        "summary": "Rotate Organization Key",
        "description": "This route allows a organization to rotate their secret key, a critical security component used for authentication and encryption in the platform.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/RotateTenantAccessTokenResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/RotateTenantAccessTokenResponse"
                }
              }
            }
          },
          "400": {
            "description": "Invalid organization secret",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            },
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Invalid organization secret"
                }
              },
              "xml": {
                "name": "main"
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal Server Error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal Server Error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/rotateKey"
              }
            },
            "application/xml": {
              "schema": {
                "$ref": "#/components/schemas/rotateKey"
              }
            }
          }
        }
      }
    },
    "/organization/delete": {
      "delete": {
        "tags": [
          "Organization"
        ],
        "summary": "Delete Organization",
        "description": "This route allows for the permanent deletion of a organization from the ecosystem, identified by their organization id. Deleting a organization removes all their associated data, including credential templates, verification templates, issued credentials, and proof requests.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DeleteTenantReponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/DeleteTenantReponse"
                }
              }
            }
          },
          "400": {
            "description": "Invalid organization secret",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            },
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Invalid organization secret"
                }
              },
              "xml": {
                "name": "main"
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal Server Error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal Server Error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/deleteTenant"
              }
            },
            "application/xml": {
              "schema": {
                "$ref": "#/components/schemas/deleteTenant"
              }
            }
          }
        }
      }
    },
    "/credential-template/jsonld/create": {
      "post": {
        "tags": [
          "Credential Templates"
        ],
        "summary": "Create Template (JSON-LD)",
        "description": "This route enables a organization to create a JSON-LD credential template, specifying the schema type, attributes, and structure for issuing JSON-LD credentials.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "201": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CreateJsonLdCredentialTemplateResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/CreateJsonLdCredentialTemplateResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            },
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Invalid credential type for ecosystem"
                }
              },
              "xml": {
                "name": "main"
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Credential template creation limit exceeded. Please upgrade your plan or contact to support."
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Credential template creation limit exceeded. Please upgrade your plan or contact to support."
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            },
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Category not found"
                }
              },
              "xml": {
                "name": "main"
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/createJsonLdCredentialTemplate"
              }
            }
          }
        }
      }
    },
    "/credential-template/jsonld/import": {
      "post": {
        "tags": [
          "Credential Templates"
        ],
        "summary": "Import Template (JSON-LD)",
        "description": "This route enables a organization to import a JSON-LD credential template by providing the schema URL. The schema is fetched from the provided URL, validated, and then resolved into a credential template within the ecosystem.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ImportJsonLdCredentialTemplateResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/ImportJsonLdCredentialTemplateResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            },
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Credential template already exists"
                }
              },
              "xml": {
                "name": "main"
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Credential template creation limit exceeded. Please upgrade your plan or contact to support."
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Credential template creation limit exceeded. Please upgrade your plan or contact to support."
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            },
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Category not found"
                }
              },
              "xml": {
                "name": "main"
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/importJsonLdCredentialTemplate"
              }
            }
          }
        }
      }
    },
    "/credential-template/": {
      "get": {
        "tags": [
          "Credential Templates"
        ],
        "summary": "Get Ecosystem Templates",
        "description": "This route retrieves all credential templates or find a specific credential template by the credential template id. The templates provide a detailed structure of the credentials, including the attributes, their types, and requirements, as defined in the schema.",
        "parameters": [
          {
            "name": "credentialTemplateId",
            "in": "query",
            "description": "By default, this endpoint returns a list of all your credential templates from current Ecosystem. You can pass a specific credentialTemplateId (in UUID format) here to filter the results and retrieve details for only that single credential template.",
            "required": false,
            "example": "123e4567-e89b-12d3-a456-426614174000",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetCredentialTemplatesResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/GetCredentialTemplatesResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "required": false
        }
      }
    },
    "/credential-template/organization": {
      "get": {
        "tags": [
          "Credential Templates"
        ],
        "summary": "Get Organization Templates",
        "description": "This route retrieves all credential templates or find a specific credential template by the credential template id created by an organization.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "credentialTemplateId",
            "in": "query",
            "description": "By default, this endpoint returns a list of all your credential templates from current organization. You can pass a specific credentialTemplateId (in UUID format) here to filter the results and retrieve details for only that single credential template.",
            "required": false,
            "example": "123e4567-e89b-12d3-a456-426614174000",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetCredentialTemplatesResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/GetCredentialTemplatesResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/credential-template/delete": {
      "delete": {
        "tags": [
          "Credential Templates"
        ],
        "summary": "Delete Template",
        "description": "This route allows a organization to delete a specific credential template by providing the credential template ID. The specified template is removed from the ecosystem, ensuring that it is no longer available for issuing credentials.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": true
                    },
                    "message": {
                      "type": "string",
                      "example": "Credential template deleted successfully"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": true
                    },
                    "message": {
                      "type": "string",
                      "example": "Credential template deleted successfully"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Credential Template not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Credential Template not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DeleteCredentialTemplate"
              }
            },
            "application/xml": {
              "schema": {
                "$ref": "#/components/schemas/DeleteCredentialTemplate"
              }
            }
          }
        }
      }
    },
    "/credential-template/update": {
      "patch": {
        "tags": [
          "Credential Templates"
        ],
        "summary": "Update Template",
        "description": "This route allows a organization to update a specific credential template by providing the schema ID. The specified template is updated with the new details provided by the organization, ensuring that the credential template remains accurate and up-to-date.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": true
                    },
                    "message": {
                      "type": "string",
                      "example": "Credential Template updated successfully"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": true
                    },
                    "message": {
                      "type": "string",
                      "example": "Credential Template updated successfully"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            },
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Invalid parameters"
                }
              },
              "xml": {
                "name": "main"
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Credential Template not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Credential Template not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            },
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Category not found"
                }
              },
              "xml": {
                "name": "main"
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateCredentialTemplate"
              }
            },
            "application/xml": {
              "schema": {
                "$ref": "#/components/schemas/UpdateCredentialTemplate"
              }
            }
          }
        }
      }
    },
    "/verification-template/jsonld/create": {
      "post": {
        "tags": [
          "Verification Templates"
        ],
        "summary": "Create Template (JSON-LD)",
        "description": "This route allows a organization to create a JSON-LD verification template, outlining the policy for verifying issued JSON-LD credentials.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "201": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CreateJsonLdVerificationTemplateResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/CreateJsonLdVerificationTemplateResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            },
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Schema context is required for PrivadoId"
                }
              },
              "xml": {
                "name": "main"
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Verification template creation limit exceeded. Please upgrade your plan or contact to support."
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Verification template creation limit exceeded. Please upgrade your plan or contact to support."
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            },
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Credential template not found"
                }
              },
              "xml": {
                "name": "main"
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/createJsonLdVerificationTemplate"
              }
            }
          }
        }
      }
    },
    "/verification-template/": {
      "get": {
        "tags": [
          "Verification Templates"
        ],
        "summary": "Get Ecosystem Templates",
        "description": "Retrieves verification templates from the current ecosystem. By default, all verification templates are returned.",
        "parameters": [
          {
            "name": "verificationTemplateId",
            "in": "query",
            "description": "Filters the result by a specific verification template id.",
            "required": false,
            "example": "123e4567-e89b-12d3-a456-426614174000",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetVerificationTemplatesResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/GetVerificationTemplatesResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/verification-template/organization": {
      "get": {
        "tags": [
          "Verification Templates"
        ],
        "summary": "Get Organization Templates",
        "description": "Retrieves verification templates for a specific organization. By default, all verification templates are returned.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "verificationTemplateId",
            "in": "query",
            "description": "Filters the result by a specific verification template id for a specific organization.",
            "required": false,
            "example": "123e4567-e89b-12d3-a456-426614174000",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetVerificationTemplatesResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/GetVerificationTemplatesResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/verification-template/delete": {
      "delete": {
        "tags": [
          "Verification Templates"
        ],
        "summary": "Delete Template by Verification Template Id",
        "description": "This route is used to delete a specific verification template by its unique id.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": true
                    },
                    "message": {
                      "type": "string",
                      "example": "Verification Template deleted successfully"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": true
                    },
                    "message": {
                      "type": "string",
                      "example": "Verification Template deleted successfully"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Verification Template not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Verification Template not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DeleteTemplateByVerificationTemplateId"
              }
            },
            "application/xml": {
              "schema": {
                "$ref": "#/components/schemas/DeleteTemplateByVerificationTemplateId"
              }
            }
          }
        }
      }
    },
    "/verification-template/update": {
      "patch": {
        "tags": [
          "Verification Templates"
        ],
        "summary": "Update Template by Verification Template Id",
        "description": "This route is used to update a specific verification template by its unique id.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": true
                    },
                    "message": {
                      "type": "string",
                      "example": "Verification Template updated successfully"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": true
                    },
                    "message": {
                      "type": "string",
                      "example": "Verification Template updated successfully"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            },
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Invalid parameters"
                }
              },
              "xml": {
                "name": "main"
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Verification Template not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Verification Template not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            },
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Category not found"
                }
              },
              "xml": {
                "name": "main"
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateTemplateByVerificationTemplateId"
              }
            },
            "application/xml": {
              "schema": {
                "$ref": "#/components/schemas/UpdateTemplateByVerificationTemplateId"
              }
            }
          }
        }
      }
    },
    "/connection/create": {
      "post": {
        "tags": [
          "Connections"
        ],
        "summary": "Create Connection Invitation",
        "description": "This route allows a tenant to establish a connection with a wallet by creating a connection invitation. Once the wallet accepts the invitation, a secure connection is established, enabling tenants to issue credentials.\n\n### Related webhook events\n\nA later action in the flow can cause Hovi to send the following event to the registered webhook URL:\n\n- [Connection Established](#tag/webhook-events/webhook/post/polygon-connection-completed)",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "201": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CreateConnectionResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/CreateConnectionResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for tenant"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for tenant"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Tenant not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Tenant not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/createConnectionInvitation"
              }
            },
            "application/xml": {
              "schema": {
                "$ref": "#/components/schemas/createConnectionInvitation"
              }
            }
          }
        },
        "externalDocs": {
          "description": "View Connection Established",
          "url": "#tag/webhook-events/webhook/post/polygon-connection-completed"
        },
        "x-hovi-webhook-events": {
          "relationship": "asynchronous-flow-outcome",
          "events": [
            {
              "label": "Connection Established",
              "recipient": "issuer organization",
              "$ref": "#/webhooks/polygon-connection-completed",
              "url": "#tag/webhook-events/webhook/post/polygon-connection-completed"
            }
          ]
        }
      }
    },
    "/connection/": {
      "get": {
        "tags": [
          "Connections"
        ],
        "summary": "Get All Connections",
        "description": "This route retrieves a list of all connections established between the organization and various wallets. Each connection represents a secure link through which the organization can issue credentials or interact with the connected wallets.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "description": "Page number for paginated results. Each page returns up to 100 results. Defaults to 1 if not provided.",
            "example": 1,
            "schema": {
              "type": "integer"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetConnectionsResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/GetConnectionsResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Connections"
        ],
        "summary": "Delete Connection",
        "description": "This route allows the organization to permanently delete an existing connection invitation, identified by its unique out of band ID.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": true
                    },
                    "message": {
                      "type": "string",
                      "example": "Connection deleted successfully"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": true
                    },
                    "message": {
                      "type": "string",
                      "example": "Connection deleted successfully"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            },
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Connection invitation not found"
                }
              },
              "xml": {
                "name": "main"
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/deleteConnection"
              }
            },
            "application/xml": {
              "schema": {
                "$ref": "#/components/schemas/deleteConnection"
              }
            }
          }
        }
      }
    },
    "/connection/find": {
      "get": {
        "tags": [
          "Connections"
        ],
        "summary": "Find Completed Connection by Invitation ID or Connection ID",
        "description": "This route retrieves detailed information about connections, identified by a unique connection ID or invitation ID. If both provided, invitationId gets priority over connectionId during the search.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "invitationId",
            "in": "query",
            "description": "Find a completed connection by the OOB invitation ID that initiated the handshake. Only available in the Privado.id ecosystem. Takes priority over connectionId if both parameters are provided.",
            "required": false,
            "example": "c971d3ba-09a8-4fc3-9de0-8f04d94390b0",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "connectionId",
            "in": "query",
            "description": "Find a completed connection by its unique connection ID. Ignored if invitationId is also provided.",
            "required": false,
            "example": "d2e8903d-e65e-4543-bfbe-ede68fb88fb2",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetConnectionResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/GetConnectionResponse"
                }
              }
            },
            "schema": {
              "$ref": "#/components/schemas/GetConnectionResponse"
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            },
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Invalid parameters"
                }
              },
              "xml": {
                "name": "main"
              }
            }
          },
          "404": {
            "description": "Not Found — the specified organization does not exist",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            },
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Internal server error"
                }
              },
              "xml": {
                "name": "main"
              }
            }
          }
        }
      }
    },
    "/connection/invitations": {
      "get": {
        "tags": [
          "Connections"
        ],
        "summary": "Get All Invitations",
        "description": "This route retrieves a list of all invitations created by the organization. Each invitation can be provided as a scannable QR code that facilitates the establishment of a connection with a wallet.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "description": "Page number for paginated results. Each page returns up to 100 results. Defaults to 1 if not provided.",
            "example": 1,
            "schema": {
              "type": "integer"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetConnectionInvitationsResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/GetConnectionInvitationsResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/connection/invitation/find": {
      "get": {
        "tags": [
          "Connections"
        ],
        "summary": "Get Invitation By Invitation Id",
        "description": "This route retrieves the details of a specific connection invitation created by the organization.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "invitationId",
            "in": "query",
            "description": "Retrive connection invitation by invitation id",
            "required": true,
            "example": "c971d3ba-09a8-4fc3-9de0-8f04d94390b0",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetConnectionInvitationResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/GetConnectionInvitationResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/credential/": {
      "get": {
        "tags": [
          "Credentials"
        ],
        "summary": "Get Credentials",
        "description": "This route retrieves a list of all verifiable credentials issued by the organization.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "description": "Page number for paginated results. Each page returns up to 100 results. Defaults to 1 if not provided.",
            "example": 1,
            "schema": {
              "type": "integer"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetAllCredentialsResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/GetAllCredentialsResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/credential/find": {
      "get": {
        "tags": [
          "Credentials"
        ],
        "summary": "Get Credential by Id",
        "description": "This route retrieves detailed information about a specific verifiable credential issued by the organization, identified by its unique credential exchange ID.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "credentialExchangeId",
            "in": "query",
            "description": "Retrive detailed record credential by credential exchange id",
            "required": true,
            "example": "123e4567-e89b-12d3-a456-426614174000",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetCredentialResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/GetCredentialResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/credential/jsonld/offer": {
      "post": {
        "tags": [
          "Credentials"
        ],
        "summary": "Offer Credential (JSON-LD)",
        "description": "This route allows the organization to generate a credential offer using the JSON-LD format. The credential issuance is based on a credential template that specifies the necessary attributes, types, and requirements.\n\n### Related webhook events\n\nA later action in the flow can cause Hovi to send the following event to the registered webhook URL:\n\n- [Credential Issued](#tag/webhook-events/webhook/post/polygon-credential-issued)",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/IssueJsonLdCredentialResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/IssueJsonLdCredentialResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Credential issuance limit exceeded. Please upgrade your plan or contact to support."
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Credential issuance limit exceeded. Please upgrade your plan or contact to support."
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Template not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Template not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/issueJsonLdCredential"
              }
            }
          }
        },
        "externalDocs": {
          "description": "View Credential Issued",
          "url": "#tag/webhook-events/webhook/post/polygon-credential-issued"
        },
        "x-hovi-webhook-events": {
          "relationship": "asynchronous-flow-outcome",
          "events": [
            {
              "label": "Credential Issued",
              "recipient": "issuer organization",
              "$ref": "#/webhooks/polygon-credential-issued",
              "url": "#tag/webhook-events/webhook/post/polygon-credential-issued"
            }
          ]
        }
      }
    },
    "/webhook/add": {
      "post": {
        "tags": [
          "Webhooks"
        ],
        "summary": "Add Webhook",
        "description": "This route allows a organization to create a webhook URL that will be triggered by Hovi upon the successful issuance of a credential.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "201": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AddWebhookResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/AddWebhookResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            },
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Webhook url already exists"
                }
              },
              "xml": {
                "name": "main"
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/addWebhook"
              }
            },
            "application/xml": {
              "schema": {
                "$ref": "#/components/schemas/addWebhook"
              }
            }
          }
        }
      }
    },
    "/webhook/": {
      "get": {
        "tags": [
          "Webhooks"
        ],
        "summary": "Get All Webhooks",
        "description": "Retrieves webhooks for a specific organization. By default, all webhooks are returned.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "webhookId",
            "in": "query",
            "description": "Filters the result by a specific webhook id.",
            "required": false,
            "example": "b1b8b362-7937-4f97-bc91-708472a9ddd6",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetWebhooksResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/GetWebhooksResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Webhooks"
        ],
        "summary": "Remove Webhooks",
        "description": "This route allows a organization to delete a webhook URL that is no longer needed. Deleting a webhook ensures that the tenant will no longer receive event notifications on the specified webhook endpoint.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/RemoveWebhookResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/RemoveWebhookResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Webhook not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Webhook not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            },
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Webhook not found"
                }
              },
              "xml": {
                "name": "main"
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/deleteWebhook"
              }
            },
            "application/xml": {
              "schema": {
                "$ref": "#/components/schemas/deleteWebhook"
              }
            }
          }
        }
      }
    },
    "/webhook/rotate-secret": {
      "post": {
        "tags": [
          "Webhooks"
        ],
        "summary": "Rotate Webhook Secret",
        "description": "This route allows an organization to rotate the signing secret for an existing webhook.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/RotateWebhookSecretResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/RotateWebhookSecretResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Webhook not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Webhook not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            },
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Webhook not found"
                }
              },
              "xml": {
                "name": "main"
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/rotateWebhookSecret"
              }
            },
            "application/xml": {
              "schema": {
                "$ref": "#/components/schemas/rotateWebhookSecret"
              }
            }
          }
        }
      }
    },
    "/verification/session/document-coverage": {
      "get": {
        "description": "",
        "responses": {
          "default": {
            "description": ""
          }
        },
        "parameters": [
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ]
      }
    },
    "/verification/session/{sessionId}/redirect-target": {
      "get": {
        "description": "",
        "parameters": [
          {
            "name": "sessionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "500": {
            "description": "Internal Server Error"
          }
        }
      }
    },
    "/verification/session/{sessionId}/id-verification/document": {
      "post": {
        "description": "",
        "parameters": [
          {
            "name": "sessionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "500": {
            "description": "Internal Server Error"
          }
        }
      }
    },
    "/verification/session/{sessionId}/id-verification/passive-liveness": {
      "post": {
        "description": "",
        "parameters": [
          {
            "name": "sessionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "500": {
            "description": "Internal Server Error"
          }
        }
      }
    },
    "/verification/session/{sessionId}/id-verification/face-match": {
      "post": {
        "description": "",
        "parameters": [
          {
            "name": "sessionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "500": {
            "description": "Internal Server Error"
          }
        }
      }
    },
    "/verification/session/{sessionId}/id-verification/ip-risk": {
      "post": {
        "description": "",
        "parameters": [
          {
            "name": "sessionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "500": {
            "description": "Internal Server Error"
          }
        }
      }
    },
    "/verification/session/{sessionId}/evidence": {
      "get": {
        "description": "",
        "parameters": [
          {
            "name": "sessionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "default": {
            "description": ""
          }
        }
      }
    },
    "/verification/send-proof-request": {
      "post": {
        "tags": [
          "Verifications"
        ],
        "summary": "Send Proof Request",
        "description": "Create a proof request for a credential holder using verification template.\n\n### Related webhook events\n\nA later action in the flow can cause Hovi to send the following event to the registered webhook URL:\n\n- [Presentation Verified](#tag/webhook-events/webhook/post/polygon-presentation-verified)",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SendProofRequestResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/SendProofRequestResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Verification limit exceeded. Please upgrade your plan or contact to support."
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Verification limit exceeded. Please upgrade your plan or contact to support."
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            },
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Verification template not found"
                }
              },
              "xml": {
                "name": "main"
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/sendProofRequest"
              }
            },
            "application/xml": {
              "schema": {
                "$ref": "#/components/schemas/sendProofRequest"
              }
            }
          }
        },
        "externalDocs": {
          "description": "View Presentation Verified",
          "url": "#tag/webhook-events/webhook/post/polygon-presentation-verified"
        },
        "x-hovi-webhook-events": {
          "relationship": "asynchronous-flow-outcome",
          "events": [
            {
              "label": "Presentation Verified",
              "recipient": "verifier organization",
              "$ref": "#/webhooks/polygon-presentation-verified",
              "url": "#tag/webhook-events/webhook/post/polygon-presentation-verified"
            }
          ]
        }
      }
    },
    "/verification/proof-request": {
      "get": {
        "tags": [
          "Verifications"
        ],
        "summary": "Get Proof Requests",
        "description": "This route retrieves all proof requests initiated by a specific organization. Proof requests are used to verify credentials that have been issued to credential holders.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "state",
            "in": "query",
            "required": false,
            "description": "Filter proof requests by state",
            "schema": {
              "type": "string",
              "enum": [
                "pending",
                "done",
                "abandoned"
              ]
            },
            "example": "pending"
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "description": "Page number for paginated results. Each page returns up to 100 results. Defaults to 1 if not provided.",
            "example": 1,
            "schema": {
              "type": "integer"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetProofRequestsResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/GetProofRequestsResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/verification/proof-request/find": {
      "get": {
        "tags": [
          "Verifications"
        ],
        "summary": "Find Proof Request by Proof Exchange Id",
        "description": "This route retrieves a specific proof request by its proof exchange id. The proof request contains details about the verification process initiated by the tenant.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "proofExchangeId",
            "in": "query",
            "description": "Specifies the proof exchange id used to retrieve a specific proof request.",
            "required": true,
            "example": "123e4567-e89b-12d3-a456-426614174000",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetProofRequestResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/GetProofRequestResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "required": false
        }
      }
    },
    "/verification/proof-response": {
      "get": {
        "tags": [
          "Verifications"
        ],
        "summary": "Get Proof Responses",
        "description": "This route retrieves all responses received from credential holders in response to the proof requests issued by a organization. Proof responses contain the presentation submitted by the credential holder to fulfill the proof request.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "description": "Page number for paginated results. Each page returns up to 100 results. Defaults to 1 if not provided.",
            "example": 1,
            "schema": {
              "type": "integer"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetProofResponsesResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/GetProofResponsesResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/verification/proof-response/find": {
      "get": {
        "tags": [
          "Verifications"
        ],
        "summary": "Find Proof Response by Presentation Id",
        "description": "This route retrieves a specific proof response by its unique presentation id or proof exchange id. The proof response contains the presentation data submitted by the credential holder in response to a particular proof request.",
        "parameters": [
          {
            "name": "x-organization-id",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The unique identifier of the organization (tenant) in UUID format.",
            "example": "123e4567-e89b-12d3-a456-426614174000"
          },
          {
            "name": "presentationId",
            "in": "query",
            "description": "Retrive detailed proof presentation by presentation id",
            "required": false,
            "example": "123e4567-e89b-12d3-a456-426614174000",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "proofExchangeId",
            "in": "query",
            "description": "Retrive detailed proof presentation by proof exchange id",
            "required": false,
            "example": "123e4567-e89b-12d3-a456-426614174000",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "description": "Ecosystem API Key. Must be prefixed with \"Bearer \".",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Bearer YOUR_ECOSYSTEM_API_KEY"
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetProofResponseByProofIdResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/GetProofResponseByProofIdResponse"
                }
              }
            },
            "schema": {
              "$ref": "#/components/schemas/GetProofResponseByProofIdResponse"
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Invalid parameters"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Ecosystem unauthorized for organization"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "404": {
            "description": "Not found",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Organization not found"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              },
              "application/xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": false
                    },
                    "message": {
                      "type": "string",
                      "example": "Internal server error"
                    }
                  },
                  "xml": {
                    "name": "main"
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "CredentialAttribute": {},
      "CredentialTheme": {
        "title": "Credential Visual Theme",
        "type": "object",
        "description": "Visual rendering metadata for the JSON-LD credential card displayed in Polygon ID-compatible wallets.",
        "example": {
          "title": "Patient ID Card",
          "description": "Proof of admission in the hospital",
          "textColor": "#000000",
          "backgroundImageUrl": "https://static.vecteezy.com/system/resources/thumbnails/011/020/176/small/abstract-white-and-light-gray-wave-modern-soft-luxury-texture-with-smooth-and-clean-background-free-vector.jpg",
          "logoUrl": "https://1000logos.net/wp-content/uploads/2016/10/ACME-Logo-1981.png",
          "logoAlt": "Acme Corp"
        },
        "properties": {
          "title": {
            "type": "string",
            "description": "Display title shown on the credential card. If omitted, the credential-template name is used."
          },
          "description": {
            "type": "string",
            "description": "Short descriptive text shown on the credential card."
          },
          "textColor": {
            "type": "string",
            "example": "#000000",
            "default": "#000000",
            "description": "Hex color code for the card text overlay. If omitted, `#000000` is used."
          },
          "backgroundImageUrl": {
            "type": "string",
            "format": "url",
            "description": "URL of the credential card background image. If omitted, a standard background image may be used."
          },
          "logoUrl": {
            "type": "string",
            "format": "url",
            "description": "URL of the issuer's logo image. If both logo fields are omitted, the organization's logo may be used. Required when `logoAlt` is provided."
          },
          "logoAlt": {
            "type": "string",
            "description": "Accessibility alt-text for the logo image. If omitted when `logoUrl` is provided, the organization's display name is used."
          }
        }
      },
      "CreateJsonLdCredentialTemplateResponse": {
        "title": "Create JSON-LD Credential Template Response",
        "type": "object",
        "description": "Returned after successfully creating a JSON-LD credential template. The schema context document is published to IPFS and the template is stored in Hovi for use in Iden3 credential issuance flows.",
        "example": {
          "success": true,
          "response": {
            "credentialTemplateId": "01b8e82f-6596-432f-85fb-4e1025bbac35",
            "schemaId": "b18ba975-bd6f-44dc-b23c-9560d2030e7a",
            "ecosystemId": "1d6e0184-e137-4a3b-bbb0-1a39216321bc",
            "organizationId": "0db20e29-b535-41f4-bff6-e4b607f59a52",
            "name": "Patient ID",
            "version": "1.0.1",
            "description": "Patient ID Card",
            "type": "jsonld",
            "image": "https://acme-corp.com/patient.png",
            "attributes": [
              {
                "name": "name",
                "label": "Name",
                "type": "string",
                "description": "Name of the patient",
                "required": true
              },
              {
                "name": "age",
                "label": "Age",
                "type": "string",
                "description": "Age of the patient",
                "required": true
              }
            ],
            "schemaUrl": "https://hovi.id/schemas/bafkreidnsspsutlwmuqhckkesbfukldxvl22ihje4wtoxo7btiqzzlsqwy",
            "schemaContext": "https://hovi.id/schemas/bafkreiajlvdphn5d53gzo4z6k6qw7us6rnphlwtyujdufdrtzds3g5tduq",
            "schemaType": "Patient",
            "createdAt": "2025-02-27T16:28:14.826Z",
            "updatedAt": "2025-02-27T16:28:14.826Z"
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates whether the credential template was successfully created."
          },
          "response": {
            "type": "object",
            "properties": {
              "credentialTemplateId": {
                "type": "string",
                "format": "uuid",
                "description": "Hovi-assigned UUID for this credential template. Use when issuing credentials."
              },
              "schemaId": {
                "type": "string",
                "format": "uuid",
                "description": "Internal Hovi UUID for the JSON-LD schema record."
              },
              "ecosystemId": {
                "type": "string",
                "format": "uuid",
                "description": "UUID of the Hovi ecosystem this template belongs to."
              },
              "organizationId": {
                "type": "string",
                "format": "uuid",
                "description": "UUID of the organization that owns this template."
              },
              "name": {
                "type": "string",
                "description": "Human-readable template name."
              },
              "version": {
                "type": "string",
                "description": "Semantic version string for this template."
              },
              "description": {
                "type": "string",
                "description": "Plain-text description of the credential type."
              },
              "type": {
                "type": "string",
                "enum": [
                  "jsonld"
                ],
                "description": "Credential format. `jsonld` — W3C JSON-LD Verifiable Credential with Iden3-compatible proof."
              },
              "image": {
                "type": "string",
                "format": "url",
                "description": "URL of the credential card image in the holder's wallet."
              },
              "attributes": {
                "type": "array",
                "description": "JSON-LD `credentialSubject` claim definitions. Supports nested object attributes.",
                "items": {
                  "$ref": "#/components/schemas/CredentialAttribute"
                }
              },
              "schemaUrl": {
                "type": "string",
                "format": "url",
                "description": "IPFS-hosted URL of the JSON schema document for this credential type."
              },
              "schemaContext": {
                "type": "string",
                "format": "url",
                "description": "IPFS-hosted JSON-LD `@context` URL mapping credential fields to semantic IRIs."
              },
              "schemaType": {
                "type": "string",
                "description": "JSON-LD `@type` value embedded in issued credentials (e.g., `\"Patient\"`)."
              },
              "createdAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp when this template was created."
              },
              "updatedAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp of the most recent update."
              }
            }
          }
        }
      },
      "UpdateTenantResponse": {
        "title": "Update Tenant Response",
        "type": "object",
        "description": "Returned after successfully updating an organization's display settings.",
        "example": {
          "success": true
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the tenant update was successful."
          }
        }
      },
      "ImportJsonLdCredentialTemplateResponse": {
        "title": "Import JSON-LD Credential Template Response",
        "type": "object",
        "description": "Returned after successfully importing an existing JSON-LD credential template by referencing a publicly hosted schema URL.",
        "example": {
          "success": true,
          "response": {
            "credentialTemplateId": "7471bb29-e875-4462-996a-69b2379a5049",
            "schemaId": "ceff35e7-8625-40f3-a0f3-316784593e29",
            "ecosystemId": "c9ba491b-988f-481d-9c33-a5cc5aaff4ed",
            "organizationId": "99f009f6-aefa-4c13-bbe9-e5e314a64b1c",
            "categoryId": "2e5f483f-8970-4c5e-baf7-991ff24c120d",
            "name": "University Degree",
            "version": "2.0.2",
            "description": "University Degree credential template",
            "type": "jsonld",
            "image": "https://brandslogos.com/wp-content/uploads/images/large/acme-logo.png",
            "attributes": [
              {
                "name": "university",
                "type": "object",
                "label": "University title",
                "description": "name of the university",
                "required": true,
                "attributes": [
                  {
                    "name": "batch",
                    "type": "object",
                    "label": "Batch title",
                    "description": "batch of the student",
                    "required": true,
                    "attributes": [
                      {
                        "name": "passingYear",
                        "type": "integer",
                        "label": "PassingYear title",
                        "description": "passing year of the student",
                        "required": true
                      }
                    ]
                  },
                  {
                    "name": "branch",
                    "type": "string",
                    "label": "Branch",
                    "description": "branch of the university",
                    "required": true
                  }
                ]
              },
              {
                "name": "fullName",
                "type": "string",
                "label": "Full Name",
                "description": "full name of the student",
                "required": true
              }
            ],
            "schemaUrl": "https://hovi.id/schemas/QmRF7nnhYTsWu8sqA2jeLWbWP9LuuARS9RrWsL2akvwD7v",
            "schemaType": "University Degree",
            "createdAt": "2024-08-12T11:21:32.464Z",
            "updatedAt": "2024-08-12T11:21:32.464Z"
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "object",
            "properties": {
              "credentialTemplateId": {
                "type": "string",
                "format": "uuid",
                "description": "Hovi-assigned UUID for the imported credential template."
              },
              "schemaId": {
                "type": "string",
                "format": "uuid",
                "description": "Internal Hovi UUID for the JSON-LD schema record."
              },
              "ecosystemId": {
                "type": "string",
                "format": "uuid",
                "description": "UUID of the Hovi ecosystem this template belongs to."
              },
              "organizationId": {
                "type": "string",
                "format": "uuid",
                "description": "UUID of the organization that performed the import."
              },
              "categoryId": {
                "type": "string",
                "format": "uuid",
                "description": "Industry/sector category UUID."
              },
              "name": {
                "type": "string",
                "description": "Human-readable name of the imported credential template."
              },
              "version": {
                "type": "string",
                "description": "Version string of the imported template."
              },
              "description": {
                "type": "string",
                "description": "Plain-text description of the imported credential template."
              },
              "type": {
                "type": "string",
                "enum": [
                  "jsonld"
                ],
                "description": "Credential format of the imported template."
              },
              "image": {
                "type": "string",
                "format": "url",
                "description": "URL of the credential card image in the holder's wallet."
              },
              "attributes": {
                "type": "array",
                "description": "Claim fields derived from the imported JSON-LD schema. Supports nested object attributes.",
                "items": {
                  "$ref": "#/components/schemas/CredentialAttribute"
                }
              },
              "schemaUrl": {
                "type": "string",
                "format": "url",
                "description": "Public URL of the imported JSON-LD schema document."
              },
              "schemaType": {
                "type": "string",
                "description": "JSON-LD `@type` value from the imported schema."
              },
              "createdAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp when this import record was created."
              },
              "updatedAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp of the most recent update."
              }
            }
          }
        }
      },
      "GetCredentialTemplatesResponse": {
        "title": "Get Credential Templates Response",
        "type": "object",
        "description": "Returned when listing all JSON-LD credential templates belonging to an organization.",
        "example": {
          "success": true,
          "response": [
            {
              "credentialTemplateId": "ae5717a4-7f04-46a2-bf42-591cd226a7e2",
              "schemaId": "ee473b74-c97a-49f9-962e-eb84b493f644",
              "ecosystemId": "1d6e0184-e137-4a3b-bbb0-1a39216321bc",
              "organizationId": "de7e7ab5-109e-44d0-966d-78aa74d81ca7",
              "name": "Patient ID",
              "version": "1.0.1",
              "description": "Patient ID Card",
              "type": "jsonld",
              "image": "https://acme-corp.com/patient.png",
              "attributes": [
                {
                  "name": "name",
                  "label": "Name",
                  "type": "string",
                  "description": "Name of the patient",
                  "required": true
                },
                {
                  "name": "age",
                  "label": "Age",
                  "type": "string",
                  "description": "Age of the patient",
                  "required": true
                }
              ],
              "schemaUrl": "https://hovi.id/schemas/bafkreicqmxe3l6xraujo7ovdanrwxeh5q5uy32prku5ma2ziogofzsydya",
              "schemaContext": "https://hovi.id/schemas/bafkreigts7qmpygexrikxf3ypmm6tvb26plf2dlv744u2vzdlbdxm24ctm",
              "schemaType": "Patient",
              "privadoCredentialType": "jsonld-sig",
              "createdAt": "2024-11-12T13:22:36.153Z",
              "updatedAt": "2024-11-12T13:22:36.153Z"
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the listing was retrieved successfully."
          },
          "response": {
            "type": "array",
            "description": "Array of all JSON-LD credential template records for this organization.",
            "items": {
              "type": "object",
              "properties": {
                "credentialTemplateId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Hovi-assigned UUID for this credential template."
                },
                "schemaId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Internal Hovi UUID for the JSON-LD schema record."
                },
                "ecosystemId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the Hovi ecosystem this template belongs to."
                },
                "organizationId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the organization that owns this template."
                },
                "name": {
                  "type": "string",
                  "description": "Human-readable template name."
                },
                "version": {
                  "type": "string",
                  "description": "Semantic version string."
                },
                "description": {
                  "type": "string",
                  "description": "Plain-text description of the credential type."
                },
                "type": {
                  "type": "string",
                  "enum": [
                    "jsonld"
                  ],
                  "description": "Credential format."
                },
                "image": {
                  "type": "string",
                  "format": "url",
                  "description": "URL of the credential card image in the holder's wallet."
                },
                "attributes": {
                  "type": "array",
                  "description": "JSON-LD `credentialSubject` claim definitions.",
                  "items": {
                    "$ref": "#/components/schemas/CredentialAttribute"
                  }
                },
                "schemaUrl": {
                  "type": "string",
                  "format": "url",
                  "description": "IPFS-hosted JSON schema URL for this credential type."
                },
                "schemaContext": {
                  "type": "string",
                  "format": "url",
                  "description": "IPFS-hosted JSON-LD `@context` URL."
                },
                "schemaType": {
                  "type": "string",
                  "description": "JSON-LD `@type` value embedded in issued credentials."
                },
                "privadoCredentialType": {
                  "type": "string",
                  "enum": [
                    "jsonld-sig",
                    "jsonld-mtp"
                  ],
                  "description": "Polygon-specific credential proof type. `jsonld-sig` — JSON-LD credential with Iden3 BJJSignature2021 proof, or `jsonld-mtp` — JSON-LD credential with Merkle Tree Proof."
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp when this template was created."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent update."
                }
              }
            }
          }
        }
      },
      "GetVerificationTemplatesResponse": {
        "title": "Get Verification Templates Response",
        "type": "object",
        "description": "Returned when listing all JSON-LD verification templates belonging to an organization. Each template contains `privadoProofScopes` defining the Iden3 `credentialAtomicQuerySigV2` circuit conditions for the proof request.",
        "example": {
          "success": true,
          "response": [
            {
              "verificationTemplateId": "796dbd9d-8b61-4180-b94d-df4a4e138378",
              "ecosystemId": "259c9647-5f27-49a7-9762-42d9231709a2",
              "organizationId": "c7a3c4ae-63d4-41d8-9d17-0fb402d4a6fd",
              "categoryId": "9636b597-cbe2-492a-bf92-87641729e6e4",
              "name": "University Degree Verification",
              "image": "https://picsum.photos/200",
              "version": "2.0.8",
              "description": "University Degree verification template",
              "type": "jsonld",
              "credentialType": "jsonld-sig",
              "privadoProofScopes": [
                {
                  "circuitId": "credentialAtomicQuerySigV2",
                  "id": 1,
                  "query": {
                    "allowedIssuers": [
                      "*"
                    ],
                    "type": "University Degree Record",
                    "credentialSubject": {
                      "university.batch.passingYear": {
                        "$in": [
                          2000,
                          2021,
                          2022
                        ]
                      }
                    }
                  }
                },
                {
                  "circuitId": "credentialAtomicQuerySigV2",
                  "id": 2,
                  "query": {
                    "allowedIssuers": [
                      "*"
                    ],
                    "type": "University Degree Record",
                    "credentialSubject": {
                      "fullName": {
                        "$eq": "John Doe"
                      }
                    }
                  }
                }
              ],
              "createdAt": "2024-08-05T11:01:31.997Z",
              "updatedAt": "2024-08-05T11:01:31.997Z"
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the listing was retrieved successfully."
          },
          "response": {
            "type": "array",
            "description": "Array of all JSON-LD verification template records for this organization.",
            "items": {
              "type": "object",
              "properties": {
                "verificationTemplateId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Hovi-assigned UUID for this verification template."
                },
                "ecosystemId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the Hovi ecosystem this template belongs to."
                },
                "organizationId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the organization that owns this template."
                },
                "categoryId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Industry/sector category UUID."
                },
                "name": {
                  "type": "string",
                  "description": "Human-readable name of the verification template."
                },
                "image": {
                  "type": "string",
                  "format": "url",
                  "description": "URL of the image shown on the proof request screen."
                },
                "version": {
                  "type": "string",
                  "description": "Semantic version string."
                },
                "description": {
                  "type": "string",
                  "description": "Plain-text description of what this template checks."
                },
                "type": {
                  "type": "string",
                  "enum": [
                    "jsonld"
                  ],
                  "description": "Credential format this template targets."
                },
                "credentialType": {
                  "type": "string",
                  "enum": [
                    "jsonld-sig"
                  ],
                  "description": "Polygon-specific credential proof type this template targets."
                },
                "privadoProofScopes": {
                  "type": "array",
                  "description": "Polygon proof scope definitions — each scope maps to one Iden3 `credentialAtomicQuerySigV2` circuit query. Multiple scopes are AND-ed together.",
                  "items": {
                    "type": "object",
                    "properties": {
                      "circuitId": {
                        "type": "string",
                        "enum": [
                          "credentialAtomicQuerySigV2"
                        ],
                        "description": "Iden3 ZK circuit used to verify this scope (`credentialAtomicQuerySigV2` — Groth16 signature-based atomic query circuit)."
                      },
                      "id": {
                        "type": "number",
                        "description": "Numeric identifier for this scope within the proof request."
                      },
                      "query": {
                        "type": "object",
                        "description": "Iden3 proof query definition for this scope.",
                        "properties": {
                          "allowedIssuers": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            },
                            "description": "Accepted issuer DIDs. `[\"*\"]` accepts credentials from any issuer."
                          },
                          "type": {
                            "type": "string",
                            "description": "JSON-LD `@type` of the credential this scope targets."
                          },
                          "context": {
                            "type": "string",
                            "format": "url",
                            "description": "Optional JSON-LD `@context` URL for the credential schema."
                          },
                          "credentialSubject": {
                            "type": "object",
                            "description": "Iden3 query conditions on credential subject fields. Supports `$eq`, `$in`, `$gt`, `$lt`, `$gte`, `$lte` operators on dot-notation field paths."
                          }
                        }
                      }
                    }
                  }
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp when this template was created."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent update."
                }
              }
            }
          }
        }
      },
      "CreateJsonLdVerificationTemplateResponse": {
        "title": "Create JSON-LD Verification Template Response",
        "type": "object",
        "description": "Returned after successfully creating a JSON-LD verification template. The template defines Iden3 `credentialAtomicQuerySigV2` proof scopes used to generate Polygon-compatible proof requests.",
        "example": {
          "success": true,
          "response": {
            "verificationTemplateId": "796dbd9d-8b61-4180-b94d-df4a4e138378",
            "ecosystemId": "259c9647-5f27-49a7-9762-42d9231709a2",
            "organizationId": "c7a3c4ae-63d4-41d8-9d17-0fb402d4a6fd",
            "categoryId": "9636b597-cbe2-492a-bf92-87641729e6e4",
            "name": "University Degree Verification",
            "image": "https://picsum.photos/200",
            "version": "2.0.8",
            "description": "University Degree verification template",
            "type": "jsonld",
            "credentialType": "jsonld-sig",
            "privadoProofScopes": [
              {
                "circuitId": "credentialAtomicQuerySigV2",
                "id": 1,
                "query": {
                  "allowedIssuers": [
                    "*"
                  ],
                  "type": "University Degree Record",
                  "credentialSubject": {
                    "university.batch.passingYear": {
                      "$in": [
                        2000,
                        2021,
                        2022
                      ]
                    }
                  }
                }
              },
              {
                "circuitId": "credentialAtomicQuerySigV2",
                "id": 2,
                "query": {
                  "allowedIssuers": [
                    "*"
                  ],
                  "type": "University Degree Record",
                  "credentialSubject": {
                    "fullName": {
                      "$eq": "John Doe"
                    }
                  }
                }
              }
            ],
            "createdAt": "2024-08-05T11:01:31.997Z",
            "updatedAt": "2024-08-05T11:01:31.997Z"
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "object",
            "properties": {
              "verificationTemplateId": {
                "type": "string",
                "format": "uuid",
                "description": "Hovi-assigned UUID for the newly created verification template."
              },
              "ecosystemId": {
                "type": "string",
                "format": "uuid",
                "description": "UUID of the Hovi ecosystem this template belongs to."
              },
              "organizationId": {
                "type": "string",
                "format": "uuid",
                "description": "UUID of the organization that created this template."
              },
              "categoryId": {
                "type": "string",
                "format": "uuid",
                "description": "Industry/sector category UUID."
              },
              "name": {
                "type": "string",
                "description": "Human-readable name of the verification template."
              },
              "image": {
                "type": "string",
                "format": "url",
                "description": "URL of the image shown on the proof request screen."
              },
              "version": {
                "type": "string",
                "description": "Semantic version string."
              },
              "description": {
                "type": "string",
                "description": "Plain-text description of what this template checks."
              },
              "type": {
                "type": "string",
                "enum": [
                  "jsonld"
                ],
                "description": "Credential format this template targets."
              },
              "credentialType": {
                "type": "string",
                "enum": [
                  "jsonld-sig"
                ],
                "description": "Polygon-specific credential proof type."
              },
              "privadoProofScopes": {
                "type": "array",
                "description": "Polygon proof scope definitions — each maps to one Iden3 `credentialAtomicQuerySigV2` circuit query.",
                "items": {
                  "type": "object",
                  "properties": {
                    "circuitId": {
                      "type": "string",
                      "enum": [
                        "credentialAtomicQuerySigV2"
                      ],
                      "description": "Iden3 ZK circuit for this scope."
                    },
                    "id": {
                      "type": "number",
                      "description": "Numeric scope identifier within the proof request."
                    },
                    "query": {
                      "type": "object",
                      "description": "Iden3 proof query for this scope.",
                      "properties": {
                        "allowedIssuers": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "Accepted issuer DIDs. `[\"*\"]` accepts any issuer."
                        },
                        "type": {
                          "type": "string",
                          "description": "JSON-LD `@type` of the target credential."
                        },
                        "credentialSubject": {
                          "type": "object",
                          "description": "Query conditions on credential subject fields using Iden3 operators (`$eq`, `$in`, `$gt`, etc.)."
                        }
                      }
                    }
                  }
                }
              },
              "createdAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp when this template was created."
              },
              "updatedAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp of the most recent update."
              }
            }
          }
        }
      },
      "AddWebhookResponse": {
        "title": "Add Webhook Response",
        "type": "object",
        "description": "Returned after successfully registering a new webhook endpoint.",
        "example": {
          "success": true,
          "response": {
            "webhookId": "7d3aae8bfbe4b8472511db2a957158e8",
            "webhookUrl": "https://kindi10.requestcatcher.com",
            "webhookSecret": "4FME20TvYrxqTHJmjOvM1OG7_amYukdYbsT8MjQUN-s"
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "object",
            "properties": {
              "webhookId": {
                "type": "string",
                "description": "Unique hex identifier for this webhook registration."
              },
              "webhookUrl": {
                "type": "string",
                "format": "url",
                "description": "HTTP callback URL that Hovi POSTs event notification payloads to."
              },
              "webhookSecret": {
                "type": "string",
                "description": "Secret used to sign webhook payloads. Generated automatically."
              }
            }
          }
        }
      },
      "RemoveWebhookResponse": {
        "title": "Remove Webhook Response",
        "type": "object",
        "description": "Returned after successfully deregistering a webhook endpoint.",
        "example": {
          "success": true,
          "message": "Webhook with id 6d98b1a8-32d9-4bd3-bd31-c4fa364d18ff deleted successfully"
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the webhook was successfully removed."
          },
          "message": {
            "type": "string",
            "description": "Human-readable confirmation message."
          }
        }
      },
      "GetWebhooksResponse": {
        "title": "Get Webhooks Response",
        "type": "object",
        "description": "Returned when listing all registered webhook endpoints for an organization.",
        "example": {
          "success": true,
          "response": [
            {
              "webhookId": "305b56ab8064dfdd801d1697795e7ab0",
              "organizationId": "9def09fb-19a1-49b5-bda5-f1954c179b2d",
              "ecosystemId": "e6e31de2-83ad-4af9-8cd9-d9861b6ee5d5",
              "url": "https://kindi10.requestcatcher.com",
              "createdAt": "2024-06-21T06:31:26.415Z",
              "updatedAt": "2024-06-21T06:31:26.415Z"
            },
            {
              "webhookId": "0f8fad7f93e617ff0e548725678e81a8",
              "organizationId": "9def09fb-19a1-49b5-bda5-f1954c179b2d",
              "ecosystemId": "e6e31de2-83ad-4af9-8cd9-d9861b6ee5d5",
              "url": "https://kindi10.requestcatcher.com",
              "createdAt": "2024-06-21T06:31:26.487Z",
              "updatedAt": "2024-06-21T06:31:26.487Z"
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "array",
            "description": "All registered webhook endpoints for the organization.",
            "items": {
              "type": "object",
              "properties": {
                "webhookId": {
                  "type": "string",
                  "description": "Unique hex identifier for this webhook registration."
                },
                "organizationId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the organization that registered this webhook."
                },
                "ecosystemId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the Hovi ecosystem this webhook belongs to."
                },
                "url": {
                  "type": "string",
                  "format": "url",
                  "description": "HTTP callback URL receiving Hovi event notification POSTs."
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp when this webhook was registered."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent update."
                }
              }
            }
          }
        }
      },
      "CreateTenantResponse": {
        "title": "Create Tenant Response",
        "type": "object",
        "description": "Returned after successfully creating a new organization (tenant). The response includes the organization identifiers, access token, display settings, the auto-provisioned `did:iden3:polygon:amoy` DID with its private key for credential signing, and any configured webhook endpoints.",
        "example": {
          "success": true,
          "response": {
            "organizationId": "1abbaba4-8604-4ef8-a01f-fa788a771795",
            "tenantId": "1abbaba4-8604-4ef8-a01f-fa788a771795",
            "setting": {
              "organizationName": "Acme Corp",
              "defaultLabel": "acme-corp",
              "image": "https://acme-corp.com/logo.png",
              "id": "1abbaba4-8604-4ef8-a01f-fa788a771795"
            },
            "accessToken": "eyJhbGciOiJIUzI1NiJ9.ZXlKMFpXNWhiblJKWkNJNklqRmhZbUpoWW1FMExUZzJNRFF0TkdWbU9DMWhNREZtTFdaaE15NjRiRzQ4WVRjM01UYzVOVElzSW1saGRDSTZNVGMzT0RRNk5UQXpPSDA9.zwwmiaG5xwWz0ZmPNo4KOoQo8LwMZE3oerFZkoK8VVk",
            "dids": [
              {
                "did": "did:iden3:polygon:amoy:xDmMUg1z43pTTy6u2W8wSsq65arWgEwVdvJiDTwQG",
                "method": "iden3",
                "privateKey": "f6vUOXNZM8aCdPLB8w51oUhDfJ6nQotB"
              }
            ],
            "webhooks": [
              {
                "webhookUrl": "https://acme-corp.com/webhook1",
                "webhookId": "96438837-9a60-42c5-b7de-95ff4ed7ec88"
              },
              {
                "webhookUrl": "https://acme-corp.com/webhook2",
                "webhookId": "e8db92af-aa89-463e-b8c9-d9d617971461"
              }
            ]
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates whether the organization was successfully created. Returns `true` on success, `false` if creation failed (e.g., duplicate organization name, quota exceeded, or invalid configuration)."
          },
          "response": {
            "type": "object",
            "description": "The newly created organization record including its identifiers, credentials, DID, and registered webhooks.",
            "properties": {
              "organizationId": {
                "type": "string",
                "format": "uuid",
                "description": "Hovi-assigned UUID uniquely identifying this organization. Shares the same value as `tenantId` — both fields refer to the same entity and can be used interchangeably when referencing this organization across Hovi APIs."
              },
              "tenantId": {
                "type": "string",
                "format": "uuid",
                "description": "Hovi-assigned UUID for this organization's tenant record. Shares the same value as `organizationId` — both fields refer to the same entity. Use this as the `x-organization-id` header value in subsequent API requests."
              },
              "setting": {
                "type": "object",
                "description": "Display and configuration settings for this organization as stored in Hovi Studio.",
                "properties": {
                  "id": {
                    "type": "string",
                    "format": "uuid",
                    "description": "UUID of this settings record — matches `organizationId` and `tenantId` for this organization."
                  },
                  "organizationName": {
                    "type": "string",
                    "description": "The full display name of the organization as it appears in Hovi Studio and in credential metadata shown in the holder's wallet (e.g., `\"Acme Corp\"`)."
                  },
                  "defaultLabel": {
                    "type": "string",
                    "description": "A URL-safe slug derived from the organization name, used as the default label for DIDComm connection invitations and internal routing (e.g., `\"acme-corp\"`)."
                  },
                  "image": {
                    "type": "string",
                    "format": "url",
                    "description": "URL of the organization's logo image displayed in Hovi Studio and in the holder's wallet during connection and credential acceptance flows."
                  }
                }
              },
              "accessToken": {
                "type": "string",
                "description": "Organization-scoped JWT used to authenticate all subsequent API requests for this organization. Pass this as the `Bearer` token in the `Authorization` header. **Store securely and treat as a secret** — this token grants full access to all operations for this organization."
              },
              "dids": {
                "type": "array",
                "description": "List of DIDs auto-provisioned for this organization at creation time. Each entry represents a cryptographic identity anchored on the Polygon Amoy testnet used for credential signing and DIDComm communication.",
                "items": {
                  "type": "object",
                  "properties": {
                    "did": {
                      "type": "string",
                      "description": "The fully-qualified `did:iden3:polygon:amoy` DID string for this organization (e.g., `did:iden3:polygon:amoy:<identifier>`). This DID is used as the issuer identifier when signing credentials and as the organization's cryptographic identity on the Polygon Amoy network."
                    },
                    "method": {
                      "type": "string",
                      "enum": [
                        "iden3"
                      ],
                      "description": "The DID method used for this organization's identifier. `iden3` indicates this DID is anchored on the Polygon Amoy network using the Iden3 protocol."
                    },
                    "privateKey": {
                      "type": "string",
                      "description": "The private key material for this DID used to sign credentials and authenticate DIDComm messages. **Store securely and never expose** — loss of this key means loss of signing capability for this DID, and exposure compromises the integrity of all credentials issued by this organization."
                    }
                  }
                }
              },
              "webhooks": {
                "type": "array",
                "description": "List of webhook endpoints registered for this organization at creation time. Each entry represents an HTTP callback URL that will receive real-time event notifications (e.g., credential state changes, connection updates) as they occur on this organization's agent.",
                "items": {
                  "type": "object",
                  "properties": {
                    "webhookId": {
                      "type": "string",
                      "format": "uuid",
                      "description": "Server-assigned UUID uniquely identifying this webhook registration. Use this ID to update or remove the webhook endpoint in subsequent API calls."
                    },
                    "webhookUrl": {
                      "type": "string",
                      "format": "url",
                      "description": "The publicly reachable HTTP callback URL that will receive POST requests containing event payloads when activity occurs on this organization's agent (e.g., `https://acme-corp.com/webhook1`)."
                    }
                  }
                }
              }
            }
          }
        }
      },
      "RotateTenantAccessTokenResponse": {
        "title": "Rotate Tenant Access Token Response",
        "type": "object",
        "description": "Returned after successfully rotating the organization's Ecosystem API Key. The previous token is immediately invalidated.",
        "example": {
          "success": true,
          "response": {
            "accessToken": "eyJhbGciOiJIUzI1NiJ9.ZXlKMFpxNWhiblJKWkNJNklqZGhORFpsT1RneUxUUTVNemt0TkRobVpDMDRabUl6TFRNeVpEaGxaVEV4T1RZMk5TSXNJbWxoZENJNk1UY3lNamcyTkRVMU5uMD0.VUejpKgvZWDHrO1SogCxixRM1S4ykQAHqpIu0XmrTvI"
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the token rotation was successful."
          },
          "response": {
            "type": "object",
            "properties": {
              "accessToken": {
                "type": "string",
                "description": "Newly generated Ecosystem API Key (JWT). Replace the previous token in all API clients immediately."
              }
            }
          }
        }
      },
      "DeleteTenantReponse": {
        "title": "Delete Tenant Response",
        "type": "object",
        "description": "Returned after successfully deleting an organization and all its associated resources. This action is irreversible.",
        "example": {
          "success": true
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the tenant was successfully deleted."
          }
        }
      },
      "GetTenantsResponse": {
        "title": "Get Tenants Response",
        "type": "object",
        "description": "Returned when listing all organizations within the Hovi ecosystem, including archived ones. Each item includes a `status` of `active` or `archived`. Optional `organizationId` query filters to a single organization.",
        "example": {
          "success": true,
          "response": [
            {
              "organizationId": "44266dea-aea5-421e-88ba-732bb774a0ea",
              "tenantId": "44266dea-aea5-421e-88ba-732bb774a0ea",
              "ecosystemId": "e245e890-5811-457e-aae2-f4d4cf5ade71",
              "dids": [
                {
                  "did": "did:iden3:polygon:amoy:x9GJM81ZjQTtc56k7voGE9q788bYH8nGhxBFYJQoC",
                  "method": "iden3"
                }
              ],
              "name": "Polygon Org",
              "label": "polygonorg",
              "image": "https://hovidevelopment.blob.core.windows.net/studio-assets/tenants/images/polygon-org-image-1778470746748.svg%2Bxml",
              "status": "active",
              "createdAt": "2026-05-11T03:39:10.931Z",
              "updatedAt": "2026-05-11T03:42:37.181Z"
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates whether the organization listing was successfully retrieved. Returns `true` even when no organizations exist (empty array). A `false` value signals a request or server-level failure."
          },
          "response": {
            "type": "array",
            "description": "Array of all organization records registered within this Hovi ecosystem, including archived ones, ordered by creation time descending. Returns an empty array if no organizations have been created yet.",
            "items": {
              "type": "object",
              "properties": {
                "organizationId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Hovi-assigned UUID uniquely identifying this organization. Shares the same value as `tenantId` — both fields refer to the same entity and can be used interchangeably when referencing this organization across Hovi APIs."
                },
                "tenantId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Hovi-assigned UUID for this organization's tenant record. Shares the same value as `organizationId`. Use this as the `x-organization-id` header value in subsequent API requests targeting this organization."
                },
                "ecosystemId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the Hovi ecosystem this organization belongs to. The ecosystem is the top-level platform partition that groups all organizations, schemas, and resources."
                },
                "dids": {
                  "type": "array",
                  "description": "List of DIDs provisioned for this organization. Each entry represents a cryptographic identity used for credential signing and DIDComm communication. Note: unlike the Create Tenant response, this listing endpoint does not return sensitive key material (`privateKey`) for security reasons.",
                  "items": {
                    "type": "object",
                    "properties": {
                      "did": {
                        "type": "string",
                        "description": "The fully-qualified DID string for this organization (e.g., `did:iden3:polygon:amoy:<identifier>`). Used as the issuer identifier when signing credentials."
                      },
                      "method": {
                        "type": "string",
                        "enum": [
                          "iden3"
                        ],
                        "description": "The DID method used for this organization's identifier. `iden3` indicates this DID is anchored on the Polygon Amoy network using the Iden3 protocol."
                      }
                    }
                  }
                },
                "name": {
                  "type": "string",
                  "description": "The full display name of the organization as it appears in Hovi Studio and in credential metadata shown in the holder's wallet (e.g., `\"Polygon Org\"`)."
                },
                "label": {
                  "type": "string",
                  "description": "A URL-safe slug derived from the organization name, used as the default label for DIDComm connection invitations and internal agent routing (e.g., `\"polygonorg\"`)."
                },
                "image": {
                  "type": "string",
                  "format": "url",
                  "description": "URL of the organization's logo image displayed in Hovi Studio and in the holder's wallet during connection and credential acceptance flows. May point to a tenant-specific asset hosted in blob storage (e.g., an `.svg+xml` asset in Azure Blob Storage)."
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "active",
                    "archived"
                  ],
                  "description": "Organization lifecycle status. `active` organizations are fully operational. `archived` organizations remain visible in listings but most mutating operations are blocked."
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of when this organization was first created in the Hovi platform."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent update to this organization record (e.g., name change, image update, or webhook modification)."
                }
              }
            }
          }
        }
      },
      "GetTenantDidsResponse": {
        "title": "Get Tenant DIDs Response",
        "type": "object",
        "description": "Returned when listing all DIDs provisioned for a specific organization on the Polygon Amoy network.",
        "example": {
          "success": true,
          "response": [
            {
              "did": "did:iden3:polygon:amoy:2qSMDANYnqEdDF3s5HpmspaH5ep2rDKR1xE89gWNDn",
              "method": "iden3"
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "array",
            "description": "Array of DIDs provisioned for the organization.",
            "items": {
              "type": "object",
              "properties": {
                "did": {
                  "type": "string",
                  "description": "Full `did:iden3:polygon:amoy` DID string."
                },
                "method": {
                  "type": "string",
                  "enum": [
                    "iden3"
                  ],
                  "description": "DID method — `iden3` for Polygon Amoy."
                }
              }
            }
          }
        }
      },
      "CreateConnectionResponse": {
        "title": "Create Connection Response",
        "type": "object",
        "description": "Returned after successfully generating an Iden3comm connection invitation. The `invitationUri` (`iden3comm://`) is encoded into a QR code or deep link for a Polygon ID-compatible holder wallet to scan and establish a peer channel.",
        "example": {
          "success": true,
          "response": {
            "invitationId": "e53e1006-5ba3-4656-b1b0-d154d2ec6f5d",
            "multiParty": true,
            "createdRequest": {
              "id": "e53e1006-5ba3-4656-b1b0-d154d2ec6f5d",
              "thid": "e53e1006-5ba3-4656-b1b0-d154d2ec6f5d",
              "typ": "application/iden3comm-plain-json",
              "type": "https://iden3-communication.io/authorization/1.0/request",
              "from": "did:iden3:polygon:amoy:2qQSaniB8hK6VRqwJVy5ch56JfYNAGFXKzKj81nQkk",
              "body": {
                "callbackUrl": "https://polygon-agent.hovi.id/connection/did-exchange/e53e1006-5ba3-4656-b1b0-d154d2ec6f5d",
                "scope": []
              }
            },
            "invitationUri": "iden3comm://?i_m=eyJpZCI6ImU1M2UxMDA2LTViYTMtNDY1Ni1iMWIwLWQxNTRkMmVjNmY1ZCIsInRoaWQiOiJlNTNlMTAwNi01YmEzLTQ2NTYtYjFiMC1kMTU0ZDJlYzZmNWQiLCJ0eXAiOiJhcHBsaWNhdGlvbi9pZGVuM2NvbW0tcGxhaW4tanNvbiIsInR5cGUiOiJodHRwczovL2lkZW4zLWNvbW11bmljYXRpb24uaW8vYXV0aG9yaXphdGlvbi8xLjAvcmVxdWVzdCJ9",
            "invitationUrl": "https://hovi.id/connection?data=eyJ1cmkiOiJpZGVuM2NvbW06Ly8...fQ=="
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates whether the connection invitation was successfully generated."
          },
          "response": {
            "type": "object",
            "properties": {
              "invitationId": {
                "type": "string",
                "format": "uuid",
                "description": "Hovi-assigned UUID for this invitation. Use to poll connection state or retrieve the Base64 invitation payload."
              },
              "multiParty": {
                "type": "boolean",
                "description": "`true` — reusable invitation; multiple wallets may connect via the same QR. `false` — single-use, expires after the first wallet completes the handshake."
              },
              "createdRequest": {
                "type": "object",
                "description": "The Iden3comm authorization request message embedded in this invitation.",
                "properties": {
                  "id": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Unique message ID of the Iden3comm request."
                  },
                  "thid": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Thread ID for correlating all messages in this connection exchange."
                  },
                  "typ": {
                    "type": "string",
                    "enum": [
                      "application/iden3comm-plain-json"
                    ],
                    "description": "Iden3comm message content type."
                  },
                  "type": {
                    "type": "string",
                    "enum": [
                      "https://iden3-communication.io/authorization/1.0/request"
                    ],
                    "description": "Iden3comm protocol message type URI."
                  },
                  "from": {
                    "type": "string",
                    "description": "Issuer DID sending this invitation (e.g., `did:iden3:polygon:amoy:...`)."
                  },
                  "body": {
                    "type": "object",
                    "description": "Iden3comm message body.",
                    "properties": {
                      "callbackUrl": {
                        "type": "string",
                        "format": "url",
                        "description": "Polygon agent callback URL where the holder wallet POSTs its DID Exchange response."
                      },
                      "scope": {
                        "type": "array",
                        "description": "Proof scopes attached to this connection request. Empty for pure connection invitations.",
                        "items": {
                          "type": "object"
                        }
                      }
                    }
                  }
                }
              },
              "invitationUri": {
                "type": "string",
                "description": "Iden3comm deep-link URI (`iden3comm://?i_m=...`) containing the Base64-encoded invitation message. Render as a QR code for wallet scanning."
              },
              "invitationUrl": {
                "type": "string",
                "format": "url",
                "description": "Hovi universal app link encapsulating the `invitationUri` for mobile wallet deep linking."
              }
            }
          }
        }
      },
      "GetConnectionsResponse": {
        "title": "Get Connections Response",
        "type": "object",
        "description": "Returned when listing all Iden3comm connection records for an organization. Each item represents a completed or pending peer channel between the organizational agent and a holder wallet.",
        "example": {
          "success": true,
          "response": [
            {
              "connectionId": "89c02ee6-c60f-4e2c-b762-45810a566376",
              "invitationId": "e53e1006-5ba3-4656-b1b0-d154d2ec6f5d",
              "response": {
                "id": "a45c227e-90c3-4054-ab03-d5bff2b89b65",
                "typ": "application/iden3-zkp-json",
                "type": "https://iden3-communication.io/authorization/1.0/response",
                "thid": "e53e1006-5ba3-4656-b1b0-d154d2ec6f5d",
                "body": {
                  "did_doc": {
                    "context": [
                      "https://www.w3.org/ns/did/v1"
                    ],
                    "id": "did:iden3:polygon:amoy:2qWFZnE6b4NQRmWpeVAaHwMGYv2ccYNoLDakLX1LiT",
                    "service": [
                      {
                        "id": "did:iden3:polygon:amoy:2qWFZnE6b4NQRmWpeVAaHwMGYv2ccYNoLDakLX1LiT#mobile",
                        "type": "Iden3MobileServiceV1",
                        "serviceEndpoint": "iden3comm:v0.1:callbackHandler"
                      },
                      {
                        "id": "did:iden3:polygon:amoy:2qWFZnE6b4NQRmWpeVAaHwMGYv2ccYNoLDakLX1LiT#push",
                        "type": "push-notification",
                        "serviceEndpoint": "https://push-staging.polygonid.com/api/v1",
                        "metadata": {
                          "devices": [
                            {
                              "ciphertext": "EGYmomYE...(truncated)",
                              "alg": "RSA-OAEP-512"
                            }
                          ]
                        }
                      }
                    ]
                  },
                  "message": null,
                  "scope": []
                },
                "from": "did:iden3:polygon:amoy:2qWFZnE6b4NQRmWpeVAaHwMGYv2ccYNoLDakLX1LiT",
                "to": "did:iden3:polygon:amoy:2qQSaniB8hK6VRqwJVy5ch56JfYNAGFXKzKj81nQkk"
              },
              "isVerified": true,
              "state": "completed",
              "createdAt": "2024-08-05T10:27:51.189Z",
              "updatedAt": "2024-08-05T10:27:51.189Z",
              "myDid": "did:iden3:polygon:amoy:2qQSaniB8hK6VRqwJVy5ch56JfYNAGFXKzKj81nQkk",
              "theirDid": "did:iden3:polygon:amoy:2qWFZnE6b4NQRmWpeVAaHwMGYv2ccYNoLDakLX1LiT"
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "array",
            "description": "All Iden3comm connection records for the organization.",
            "items": {
              "type": "object",
              "properties": {
                "connectionId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Hovi-assigned UUID for this connection record."
                },
                "invitationId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the invitation that initiated this connection."
                },
                "response": {
                  "type": "object",
                  "description": "The Iden3comm authorization response message submitted by the holder's wallet.",
                  "properties": {
                    "id": {
                      "type": "string",
                      "format": "uuid",
                      "description": "Unique message ID of the holder response."
                    },
                    "typ": {
                      "type": "string",
                      "description": "Iden3comm content type of the response message."
                    },
                    "type": {
                      "type": "string",
                      "description": "Iden3comm protocol message type URI."
                    },
                    "thid": {
                      "type": "string",
                      "format": "uuid",
                      "description": "Thread ID correlating this response to the originating invitation."
                    },
                    "body": {
                      "type": "object",
                      "description": "Iden3comm message body containing the DID document and optional proof scope.",
                      "properties": {
                        "did_doc": {
                          "type": "object",
                          "description": "Holder's DID document submitted during the connection handshake.",
                          "properties": {
                            "context": {
                              "type": "array",
                              "items": {
                                "type": "string"
                              },
                              "description": "JSON-LD contexts for the DID document."
                            },
                            "id": {
                              "type": "string",
                              "description": "Holder's `did:iden3:polygon:amoy` DID."
                            },
                            "service": {
                              "type": "array",
                              "description": "Service endpoints registered in the holder's DID document.",
                              "items": {
                                "type": "object",
                                "properties": {
                                  "id": {
                                    "type": "string",
                                    "description": "Service endpoint identifier."
                                  },
                                  "type": {
                                    "type": "string",
                                    "description": "Service type (e.g., `Iden3MobileServiceV1`, `push-notification`)."
                                  },
                                  "serviceEndpoint": {
                                    "type": "string",
                                    "description": "URL or URI of the service endpoint."
                                  },
                                  "metadata": {
                                    "type": "object",
                                    "description": "Optional metadata for the service (e.g., push notification device ciphertext)."
                                  }
                                }
                              }
                            }
                          }
                        },
                        "message": {
                          "type": "string",
                          "nullable": true,
                          "description": "Optional message attached to the connection response."
                        },
                        "scope": {
                          "type": "array",
                          "description": "Proof scopes included in this response. Empty for pure connection responses.",
                          "items": {
                            "type": "object"
                          }
                        }
                      }
                    },
                    "from": {
                      "type": "string",
                      "description": "Holder's `did:iden3:polygon:amoy` DID."
                    },
                    "to": {
                      "type": "string",
                      "description": "Issuer's `did:iden3:polygon:amoy` DID."
                    }
                  }
                },
                "isVerified": {
                  "type": "boolean",
                  "description": "Whether the Iden3comm authorization response passed cryptographic verification."
                },
                "state": {
                  "type": "string",
                  "enum": [
                    "pending",
                    "completed",
                    "abandoned"
                  ],
                  "description": "Connection lifecycle state."
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp when this connection record was created."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent state change."
                },
                "myDid": {
                  "type": "string",
                  "description": "This organization's `did:iden3:polygon:amoy` DID for this connection."
                },
                "theirDid": {
                  "type": "string",
                  "description": "Holder's `did:iden3:polygon:amoy` DID."
                }
              }
            }
          }
        }
      },
      "GetConnectionResponse": {
        "title": "Get Connection Response",
        "type": "object",
        "description": "Returned when retrieving a specific connection record by `connectionId`.",
        "example": {
          "success": true,
          "response": [
            {
              "connectionId": "5f3d9cc9-6ce1-434e-af8e-c7df69a46bcb",
              "myDid": "did:iden3:polygon:amoy:2qQSaniB8hK6VRqwJVy5ch56JfYNAGFXKzKj81nQkk",
              "createdAt": "2024-08-07T08:35:16.911Z",
              "updatedAt": "2024-08-07T08:35:32.939Z",
              "theirDid": "did:iden3:polygon:amoy:2qWFZnE6b4NQRmWpeVAaHwMGYv2ccYNoLDakLX1LiT",
              "state": "completed",
              "invitationId": "ab209278-db43-45dc-b74e-56a0d83c6f50"
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "array",
            "description": "Matched connection record(s), or empty array if not found.",
            "items": {
              "type": "object",
              "properties": {
                "connectionId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Hovi-assigned UUID for this connection."
                },
                "myDid": {
                  "type": "string",
                  "description": "This organization's `did:iden3:polygon:amoy` DID."
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp when this connection was created."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent state change."
                },
                "theirDid": {
                  "type": "string",
                  "description": "Holder's `did:iden3:polygon:amoy` DID."
                },
                "state": {
                  "type": "string",
                  "enum": [
                    "pending",
                    "completed",
                    "abandoned"
                  ],
                  "description": "Connection lifecycle state."
                },
                "invitationId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the invitation that initiated this connection."
                }
              }
            }
          }
        }
      },
      "GetConnectionsForInvitationResponse": {
        "title": "Get Connections For Invitation Response",
        "type": "object",
        "description": "Returned when listing all connection records associated with a specific invitation ID. Useful for multi-party invitations where multiple wallets may have connected via the same QR code.",
        "example": {
          "success": true,
          "response": [
            {
              "connectionId": "89c02ee6-c60f-4e2c-b762-45810a566376",
              "invitationId": "e53e1006-5ba3-4656-b1b0-d154d2ec6f5d",
              "isVerified": true,
              "state": "completed",
              "createdAt": "2024-08-05T10:27:51.189Z",
              "updatedAt": "2024-08-05T10:27:51.189Z",
              "myDid": "did:iden3:polygon:amoy:2qQSaniB8hK6VRqwJVy5ch56JfYNAGFXKzKj81nQkk",
              "theirDid": "did:iden3:polygon:amoy:2qWFZnE6b4NQRmWpeVAaHwMGYv2ccYNoLDakLX1LiT"
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "array",
            "description": "All connection records for the specified invitation.",
            "items": {
              "type": "object",
              "properties": {
                "connectionId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Hovi-assigned UUID for this connection."
                },
                "invitationId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the invitation that initiated this connection."
                },
                "isVerified": {
                  "type": "boolean",
                  "description": "Whether the Iden3comm handshake passed cryptographic verification."
                },
                "state": {
                  "type": "string",
                  "enum": [
                    "pending",
                    "completed",
                    "abandoned"
                  ],
                  "description": "Connection lifecycle state."
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp when this connection was created."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent state change."
                },
                "myDid": {
                  "type": "string",
                  "description": "This organization's `did:iden3:polygon:amoy` DID."
                },
                "theirDid": {
                  "type": "string",
                  "description": "Holder's `did:iden3:polygon:amoy` DID."
                }
              }
            }
          }
        }
      },
      "GetConnectionInvitationsResponse": {
        "title": "Get Connection Invitations Response",
        "type": "object",
        "description": "Returned when listing all Iden3comm connection invitations created by the organization.",
        "example": {
          "success": true,
          "response": [
            {
              "createdAt": "2024-08-05T10:18:14.374Z",
              "updatedAt": "2024-08-05T10:27:51.442Z",
              "invitationId": "e53e1006-5ba3-4656-b1b0-d154d2ec6f5d",
              "multiParty": true,
              "numberOfResponses": 1,
              "state": "pending"
            },
            {
              "createdAt": "2024-08-06T05:53:25.274Z",
              "updatedAt": "2024-08-06T05:54:25.177Z",
              "invitationId": "x69z004-5ba3-4656-b1b0-d154d2ec6e2d",
              "multiParty": true,
              "numberOfResponses": 2,
              "state": "pending"
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "array",
            "description": "All connection invitations created by this organization.",
            "items": {
              "type": "object",
              "properties": {
                "invitationId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Unique identifier for this invitation."
                },
                "multiParty": {
                  "type": "boolean",
                  "description": "`true` — reusable invitation. `false` — single-use."
                },
                "numberOfResponses": {
                  "type": "number",
                  "description": "Number of wallets that have responded to this invitation."
                },
                "state": {
                  "type": "string",
                  "enum": [
                    "pending",
                    "completed",
                    "abandoned"
                  ],
                  "description": "Current invitation lifecycle state."
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp when this invitation was created."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent update."
                }
              }
            }
          }
        }
      },
      "GetConnectionInvitationResponse": {
        "title": "Get Connection Invitation Response",
        "type": "object",
        "description": "Returned when retrieving a specific Iden3comm connection invitation by its ID. Includes the full invitation URI and the original Iden3comm request message.",
        "example": {
          "success": true,
          "response": {
            "invitationId": "18e3739d-7f6e-4865-a0b8-092e72119f6c",
            "createdAt": "2024-07-29T11:06:35.166Z",
            "updatedAt": "2024-07-29T11:12:34.642Z",
            "invitationUri": "iden3comm://?i_m=eyJpZCI6IjE4ZTM3MzlkLTdmNmUtNDg2NS1hMGI4LTA5MmU3MjExOWY2YyIsInRoaWQiOiIxOGUzNzM5ZC03ZjZlLTQ4NjUtYTBiOC0wOTJlNzIxMTlmNmMi...(truncated)",
            "invitationUrl": "https://hovi.id/connection?data=eyJ1cmkiOiJpZGVuM2NvbW06Ly8...(truncated)",
            "multiParty": true,
            "numberOfResponses": 1,
            "state": "pending",
            "requestType": "did_exchange",
            "request": {
              "id": "18e3739d-7f6e-4865-a0b8-092e72119f6c",
              "thid": "18e3739d-7f6e-4865-a0b8-092e72119f6c",
              "typ": "application/iden3comm-plain-json",
              "type": "https://iden3-communication.io/authorization/1.0/request",
              "from": "did:iden3:polygon:amoy:2qUNf93PcLdfieMRDaiuGEzwfZvWZL6EbGWvSbiFUF",
              "body": {
                "callbackUrl": "https://polygon-agent.hovi.id/connection/did-exchange/18e3739d-7f6e-4865-a0b8-092e72119f6c",
                "scope": []
              }
            }
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "object",
            "properties": {
              "invitationId": {
                "type": "string",
                "format": "uuid",
                "description": "Unique identifier for this invitation."
              },
              "createdAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp when this invitation was created."
              },
              "updatedAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp of the most recent update."
              },
              "invitationUri": {
                "type": "string",
                "description": "Iden3comm deep-link URI (`iden3comm://?i_m=...`) for wallet scanning."
              },
              "invitationUrl": {
                "type": "string",
                "format": "url",
                "description": "Hovi universal app link encapsulating the `invitationUri`."
              },
              "multiParty": {
                "type": "boolean",
                "description": "`true` — reusable invitation. `false` — single-use."
              },
              "numberOfResponses": {
                "type": "number",
                "description": "Number of wallets that have responded to this invitation."
              },
              "state": {
                "type": "string",
                "enum": [
                  "pending",
                  "completed",
                  "abandoned"
                ],
                "description": "Current invitation lifecycle state."
              },
              "requestType": {
                "type": "string",
                "enum": [
                  "did_exchange",
                  "presentation_exchange_request",
                  "credential_exchange_request"
                ],
                "description": "Type of Iden3comm exchange this invitation initiates."
              },
              "request": {
                "type": "object",
                "description": "The full Iden3comm authorization request message embedded in this invitation.",
                "properties": {
                  "id": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Unique message ID."
                  },
                  "thid": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Thread ID for this exchange."
                  },
                  "typ": {
                    "type": "string",
                    "description": "Iden3comm content type."
                  },
                  "type": {
                    "type": "string",
                    "description": "Iden3comm protocol message type URI."
                  },
                  "from": {
                    "type": "string",
                    "description": "Issuer's `did:iden3:polygon:amoy` DID."
                  },
                  "body": {
                    "type": "object",
                    "properties": {
                      "callbackUrl": {
                        "type": "string",
                        "format": "url",
                        "description": "Polygon agent callback URL for the holder response."
                      },
                      "scope": {
                        "type": "array",
                        "description": "Proof scopes. Empty for DID exchange invitations.",
                        "items": {
                          "type": "object"
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "SendProofRequestResponse": {
        "title": "Send Proof Request Response",
        "type": "object",
        "description": "Returned after successfully initiating a Polygon proof request. The `proofRequestUri` (`iden3comm://`) and `verificationUrl` are encoded into a QR code or deep link for the holder wallet to scan and submit a ZK proof.",
        "example": {
          "success": true,
          "response": {
            "proofExchangeId": "ac63dbf7-29dd-44e3-bf0d-3788b09e12b5",
            "verificationUrl": "https://hovi.id/verification?data=eyJ1cmkiOiJpZGVuM2NvbW06Ly8...(truncated)",
            "proofRequestUri": "iden3comm://?i_m=eyJpZCI6ImFjNjNkYmY3...(truncated)",
            "createdRequest": {
              "id": "ac63dbf7-29dd-44e3-bf0d-3788b09e12b5",
              "thid": "ac63dbf7-29dd-44e3-bf0d-3788b09e12b5",
              "typ": "application/iden3comm-plain-json",
              "type": "https://iden3-communication.io/authorization/1.0/request",
              "from": "did:iden3:polygon:amoy:2qQSaniB8hK6VRqwJVy5ch56JfYNAGFXKzKj81nQkk",
              "body": {
                "callbackUrl": "https://polygon-agent-dev.hovi.id/proof/verify-presentation/ac63dbf7-29dd-44e3-bf0d-3788b09e12b5",
                "scope": [
                  {
                    "circuitId": "credentialAtomicQuerySigV2",
                    "id": 1,
                    "query": {
                      "allowedIssuers": [
                        "*"
                      ],
                      "type": "University Degree Record 7",
                      "credentialSubject": {
                        "university.batch.passingYear": {
                          "$in": [
                            2000,
                            2021,
                            2022
                          ]
                        }
                      }
                    }
                  },
                  {
                    "circuitId": "credentialAtomicQuerySigV2",
                    "id": 2,
                    "query": {
                      "allowedIssuers": [
                        "*"
                      ],
                      "type": "University Degree Record 7",
                      "credentialSubject": {
                        "fullName": {
                          "$eq": "John Doe"
                        }
                      }
                    }
                  }
                ]
              }
            }
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the proof request was successfully initiated."
          },
          "response": {
            "type": "object",
            "properties": {
              "proofExchangeId": {
                "type": "string",
                "format": "uuid",
                "description": "Hovi-assigned UUID for this proof exchange session. Use to poll for state and retrieve ZK proof responses."
              },
              "verificationUrl": {
                "type": "string",
                "format": "url",
                "description": "Hovi universal app link encapsulating the proof request for mobile wallet deep linking."
              },
              "proofRequestUri": {
                "type": "string",
                "description": "Iden3comm deep-link URI (`iden3comm://?i_m=...`) for wallet scanning. Encode as QR code for holder presentation."
              },
              "createdRequest": {
                "type": "object",
                "description": "The full Iden3comm authorization request message for this proof exchange.",
                "properties": {
                  "id": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Unique message ID of the proof request."
                  },
                  "thid": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Thread ID correlating all messages in this proof exchange."
                  },
                  "typ": {
                    "type": "string",
                    "enum": [
                      "application/iden3comm-plain-json"
                    ],
                    "description": "Iden3comm content type."
                  },
                  "type": {
                    "type": "string",
                    "enum": [
                      "https://iden3-communication.io/authorization/1.0/request"
                    ],
                    "description": "Iden3comm protocol message type URI."
                  },
                  "from": {
                    "type": "string",
                    "description": "Verifier's `did:iden3:polygon:amoy` DID."
                  },
                  "body": {
                    "type": "object",
                    "properties": {
                      "callbackUrl": {
                        "type": "string",
                        "format": "url",
                        "description": "Polygon agent callback URL where the holder wallet POSTs its ZK proof response."
                      },
                      "scope": {
                        "type": "array",
                        "description": "Iden3 proof scope definitions — each maps to one `credentialAtomicQuerySigV2` circuit query.",
                        "items": {
                          "type": "object",
                          "properties": {
                            "circuitId": {
                              "type": "string",
                              "enum": [
                                "credentialAtomicQuerySigV2"
                              ],
                              "description": "Iden3 ZK circuit for this scope."
                            },
                            "id": {
                              "type": "number",
                              "description": "Numeric scope identifier."
                            },
                            "query": {
                              "type": "object",
                              "properties": {
                                "allowedIssuers": {
                                  "type": "array",
                                  "items": {
                                    "type": "string"
                                  },
                                  "description": "Accepted issuer DIDs."
                                },
                                "type": {
                                  "type": "string",
                                  "description": "JSON-LD `@type` of the target credential."
                                },
                                "credentialSubject": {
                                  "type": "object",
                                  "description": "Query conditions on credential subject fields."
                                }
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "GetProofRequestsResponse": {
        "title": "Get Proof Requests Response",
        "type": "object",
        "description": "Returned when listing all proof exchange records for the organization.",
        "example": {
          "success": true,
          "response": [
            {
              "proofExchangeId": "acd42bba-891b-4577-9218-a51ce3f67e37",
              "state": "done",
              "isVerified": true,
              "createdAt": "2024-08-02T11:35:13.926Z",
              "updatedAt": "2024-08-02T11:38:54.481Z",
              "numberOfResponses": 1
            },
            {
              "proofExchangeId": "5896d0ce-8b0b-4de4-a76e-ab01c0bb72f8",
              "state": "pending",
              "isVerified": false,
              "createdAt": "2024-08-02T11:42:54.065Z",
              "updatedAt": "2024-08-02T11:42:54.065Z",
              "numberOfResponses": 0
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "array",
            "description": "All proof exchange records for the organization.",
            "items": {
              "type": "object",
              "properties": {
                "proofExchangeId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Unique identifier for this proof exchange session."
                },
                "state": {
                  "type": "string",
                  "enum": [
                    "pending",
                    "done",
                    "abandoned"
                  ],
                  "description": "Proof exchange state. `done` — ZK proof received and verified."
                },
                "isVerified": {
                  "type": "boolean",
                  "description": "Whether the submitted ZK proof passed cryptographic verification."
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp when this proof exchange was initiated."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent state change."
                },
                "numberOfResponses": {
                  "type": "number",
                  "description": "Number of ZK proof responses received for this exchange."
                }
              }
            }
          }
        }
      },
      "GetProofRequestResponse": {
        "title": "Get Proof Request Response",
        "type": "object",
        "description": "Returned when retrieving a single proof exchange by ID. When `state` is `done`, includes the full Iden3comm request message, `requestType`, `verificationUrl`, and `proofRequestUri`.",
        "example": {
          "success": true,
          "response": {
            "proofExchangeId": "acd42bba-891b-4577-9218-a51ce3f67e37",
            "state": "done",
            "isVerified": true,
            "createdAt": "2024-08-02T11:35:13.926Z",
            "updatedAt": "2024-08-02T11:38:54.481Z",
            "isMultiParty": false,
            "numberOfResponses": 1,
            "requestType": "presentation_exchange_request",
            "verificationUrl": "https://hovi.id/verification?data=eyJ1cmkiOiJpZGVuM2NvbW06Ly8...(truncated)",
            "proofRequestUri": "iden3comm://?i_m=eyJpZCI6ImFjZDQyYmJhLTg5MWItNDU3Ny05MjE4...(truncated)",
            "request": {
              "id": "acd42bba-891b-4577-9218-a51ce3f67e37",
              "thid": "acd42bba-891b-4577-9218-a51ce3f67e37",
              "typ": "application/iden3comm-plain-json",
              "type": "https://iden3-communication.io/authorization/1.0/request",
              "from": "did:iden3:polygon:amoy:2qUNf93PcLdfieMRDaiuGEzwfZvWZL6EbGWvSbiFUF",
              "body": {
                "callbackUrl": "https://polygon-agent-dev.hovi.id/proof/verify-presentation/acd42bba-891b-4577-9218-a51ce3f67e37",
                "scope": [
                  {
                    "circuitId": "credentialAtomicQuerySigV2",
                    "id": 1722589673,
                    "query": {
                      "allowedIssuers": [
                        "*"
                      ],
                      "context": "https://hovi.id/schemas/QmPxUiou4B8A5ee8udcfY1GUxU4CehTi8ZtuSh1wivhqmx",
                      "type": "University Degree Record 7",
                      "credentialSubject": {
                        "university.batch.passingYear": {
                          "$gt": 2000
                        }
                      }
                    }
                  }
                ]
              }
            }
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "object",
            "properties": {
              "proofExchangeId": {
                "type": "string",
                "format": "uuid",
                "description": "Unique identifier for this proof exchange session."
              },
              "state": {
                "type": "string",
                "enum": [
                  "pending",
                  "done",
                  "abandoned"
                ],
                "description": "Current proof exchange state."
              },
              "isVerified": {
                "type": "boolean",
                "description": "Whether the ZK proof response passed cryptographic verification."
              },
              "createdAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp when this proof exchange was initiated."
              },
              "updatedAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp of the most recent state change."
              },
              "isMultiParty": {
                "type": "boolean",
                "description": "Whether this proof request accepts responses from multiple holder wallets."
              },
              "numberOfResponses": {
                "type": "number",
                "description": "Number of ZK proof responses received."
              },
              "requestType": {
                "type": "string",
                "enum": [
                  "presentation_exchange_request",
                  "credential_exchange_request",
                  "did_exchange"
                ],
                "description": "Type of Iden3comm exchange this proof request initiated."
              },
              "verificationUrl": {
                "type": "string",
                "format": "url",
                "description": "Hovi universal app link for mobile wallet deep linking."
              },
              "proofRequestUri": {
                "type": "string",
                "description": "Iden3comm deep-link URI for wallet QR scanning."
              },
              "request": {
                "type": "object",
                "description": "The full Iden3comm authorization request message for this proof exchange.",
                "properties": {
                  "id": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Unique message ID."
                  },
                  "thid": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Thread ID."
                  },
                  "typ": {
                    "type": "string",
                    "description": "Iden3comm content type."
                  },
                  "type": {
                    "type": "string",
                    "description": "Iden3comm protocol message type URI."
                  },
                  "from": {
                    "type": "string",
                    "description": "Verifier's `did:iden3:polygon:amoy` DID."
                  },
                  "body": {
                    "type": "object",
                    "properties": {
                      "callbackUrl": {
                        "type": "string",
                        "format": "url",
                        "description": "Polygon agent callback URL for holder ZK proof responses."
                      },
                      "scope": {
                        "type": "array",
                        "description": "Proof scope definitions for this request.",
                        "items": {
                          "type": "object",
                          "properties": {
                            "circuitId": {
                              "type": "string",
                              "enum": [
                                "credentialAtomicQuerySigV2"
                              ],
                              "description": "Iden3 ZK circuit."
                            },
                            "id": {
                              "type": "number",
                              "description": "Numeric scope identifier."
                            },
                            "query": {
                              "type": "object",
                              "properties": {
                                "allowedIssuers": {
                                  "type": "array",
                                  "items": {
                                    "type": "string"
                                  },
                                  "description": "Accepted issuers."
                                },
                                "context": {
                                  "type": "string",
                                  "format": "url",
                                  "description": "JSON-LD `@context` URL for the credential schema."
                                },
                                "type": {
                                  "type": "string",
                                  "description": "JSON-LD `@type` of the target credential."
                                },
                                "credentialSubject": {
                                  "type": "object",
                                  "description": "Query conditions on credential subject fields."
                                }
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "GetProofResponsesResponse": {
        "title": "Get Proof Responses Response",
        "type": "object",
        "description": "Returned when listing all ZK proof responses for a proof exchange. Each item contains the holder's full Iden3comm authorization response and the associated ZK proof data.",
        "example": {
          "success": true,
          "response": [
            {
              "createdAt": "2024-08-06T11:29:03.807Z",
              "updatedAt": "2024-08-06T11:29:03.807Z",
              "proofExchangeId": "b030a308-8ede-4339-be4c-7c91651056fd",
              "isVerified": true,
              "presentationId": "0f6bf2a7-4f99-4253-bd44-5299cf904ac5",
              "response": {
                "id": "140f5673-8c4d-49df-ad98-693ad0278554",
                "typ": "application/iden3-zkp-json",
                "type": "https://iden3-communication.io/authorization/1.0/response",
                "thid": "b030a308-8ede-4339-be4c-7c91651056fd",
                "from": "did:iden3:polygon:amoy:2qUts7TyXR7TPD4EfEtvh9EvCuR8NEjokpkWzGMRdN",
                "to": "did:iden3:polygon:amoy:2qUNf93PcLdfieMRDaiuGEzwfZvWZL6EbGWvSbiFUF",
                "body": {
                  "did_doc": {
                    "context": [
                      "https://www.w3.org/ns/did/v1"
                    ],
                    "id": "did:iden3:polygon:amoy:2qUts7TyXR7TPD4EfEtvh9EvCuR8NEjokpkWzGMRdN",
                    "service": [
                      {
                        "id": "did:iden3:polygon:amoy:2qUts7TyXR7TPD4EfEtvh9EvCuR8NEjokpkWzGMRdN#mobile",
                        "type": "Iden3MobileServiceV1",
                        "serviceEndpoint": "iden3comm:v0.1:callbackHandler"
                      },
                      {
                        "id": "did:iden3:polygon:amoy:2qUts7TyXR7TPD4EfEtvh9EvCuR8NEjokpkWzGMRdN#push",
                        "type": "push-notification",
                        "serviceEndpoint": "https://push-staging.polygonid.com/api/v1",
                        "metadata": {
                          "devices": [
                            {
                              "ciphertext": "0dy1wf8F5b...(truncated)",
                              "alg": "RSA-OAEP-512"
                            }
                          ]
                        }
                      }
                    ]
                  },
                  "message": null,
                  "scope": []
                }
              }
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "array",
            "description": "All ZK proof response records for this proof exchange.",
            "items": {
              "type": "object",
              "properties": {
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp when this proof response was received."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent update."
                },
                "proofExchangeId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the proof exchange this response belongs to."
                },
                "isVerified": {
                  "type": "boolean",
                  "description": "Whether this ZK proof response passed cryptographic verification."
                },
                "presentationId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Unique identifier for this specific proof presentation response."
                },
                "response": {
                  "type": "object",
                  "description": "Full Iden3comm authorization response submitted by the holder's wallet.",
                  "properties": {
                    "id": {
                      "type": "string",
                      "format": "uuid",
                      "description": "Unique message ID of the response."
                    },
                    "typ": {
                      "type": "string",
                      "description": "Iden3comm ZK JSON content type (`application/iden3-zkp-json`)."
                    },
                    "type": {
                      "type": "string",
                      "description": "Iden3comm protocol message type URI."
                    },
                    "thid": {
                      "type": "string",
                      "format": "uuid",
                      "description": "Thread ID correlating this response to the proof request."
                    },
                    "from": {
                      "type": "string",
                      "description": "Holder's `did:iden3:polygon:amoy` DID."
                    },
                    "to": {
                      "type": "string",
                      "description": "Verifier's `did:iden3:polygon:amoy` DID."
                    },
                    "body": {
                      "type": "object",
                      "properties": {
                        "did_doc": {
                          "type": "object",
                          "description": "Holder's DID document submitted with the proof response."
                        },
                        "message": {
                          "type": "string",
                          "nullable": true,
                          "description": "Optional message from the holder."
                        },
                        "scope": {
                          "type": "array",
                          "description": "Array of Groth16 ZK proof objects — one per proof scope in the original request.",
                          "items": {
                            "type": "object",
                            "properties": {
                              "proof": {
                                "type": "object",
                                "description": "Groth16 ZK proof data.",
                                "properties": {
                                  "pi_a": {
                                    "type": "array",
                                    "items": {
                                      "type": "string"
                                    },
                                    "description": "Groth16 proof element A (G1 point)."
                                  },
                                  "pi_b": {
                                    "type": "array",
                                    "items": {
                                      "type": "array",
                                      "items": {
                                        "type": "string"
                                      }
                                    },
                                    "description": "Groth16 proof element B (G2 point)."
                                  },
                                  "pi_c": {
                                    "type": "array",
                                    "items": {
                                      "type": "string"
                                    },
                                    "description": "Groth16 proof element C (G1 point)."
                                  },
                                  "protocol": {
                                    "type": "string",
                                    "enum": [
                                      "groth16"
                                    ],
                                    "description": "ZK proof protocol."
                                  },
                                  "curve": {
                                    "type": "string",
                                    "enum": [
                                      "bn128"
                                    ],
                                    "description": "Elliptic curve used for the proof."
                                  }
                                }
                              },
                              "pub_signals": {
                                "type": "array",
                                "items": {
                                  "type": "string"
                                },
                                "description": "Public signals for the Groth16 proof verifier."
                              },
                              "id": {
                                "type": "number",
                                "description": "Scope ID matching the original proof request scope."
                              },
                              "circuitId": {
                                "type": "string",
                                "enum": [
                                  "credentialAtomicQuerySigV2"
                                ],
                                "description": "Iden3 ZK circuit used to generate this proof."
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "GetProofResponseResponse": {
        "title": "Get Proof Response Response",
        "type": "object",
        "description": "Returned when retrieving a single ZK proof response by `presentationId`. Contains the full Groth16 proof payload including `pi_a`, `pi_b`, `pi_c`, `pub_signals`, and the Iden3comm DID document.",
        "example": {
          "success": true,
          "response": {
            "createdAt": "2024-08-02T11:38:54.237Z",
            "updatedAt": "2024-08-02T11:38:54.237Z",
            "proofExchangeId": "acd42bba-891b-4577-9218-a51ce3f67e37",
            "isVerified": true,
            "presentationId": "d78c9b23-427e-402c-a8d6-25bbee602597",
            "response": {
              "id": "1e163901-00f5-410d-b0ea-f888f857d300",
              "typ": "application/iden3-zkp-json",
              "type": "https://iden3-communication.io/authorization/1.0/response",
              "thid": "acd42bba-891b-4577-9218-a51ce3f67e37",
              "from": "did:iden3:polygon:amoy:2qUts7TyXR7TPD4EfEtvh9EvCuR8NEjokpkWzGMRdN",
              "to": "did:iden3:polygon:amoy:2qUNf93PcLdfieMRDaiuGEzwfZvWZL6EbGWvSbiFUF",
              "body": {
                "did_doc": {
                  "context": [
                    "https://www.w3.org/ns/did/v1"
                  ],
                  "id": "did:iden3:polygon:amoy:2qUts7TyXR7TPD4EfEtvh9EvCuR8NEjokpkWzGMRdN",
                  "service": [
                    {
                      "id": "did:iden3:polygon:amoy:2qUts7TyXR7TPD4EfEtvh9EvCuR8NEjokpkWzGMRdN#mobile",
                      "type": "Iden3MobileServiceV1",
                      "serviceEndpoint": "iden3comm:v0.1:callbackHandler"
                    },
                    {
                      "id": "did:iden3:polygon:amoy:2qUts7TyXR7TPD4EfEtvh9EvCuR8NEjokpkWzGMRdN#push",
                      "type": "push-notification",
                      "serviceEndpoint": "https://push-staging.polygonid.com/api/v1",
                      "metadata": {
                        "devices": [
                          {
                            "ciphertext": "R6hNVQDV...(truncated)",
                            "alg": "RSA-OAEP-512"
                          }
                        ]
                      }
                    }
                  ]
                },
                "message": null,
                "scope": [
                  {
                    "proof": {
                      "pi_a": [
                        "1841402755199166250034242792535067262511410558683553810159510627777942956614",
                        "125744564865622775266902447469709365381043967692055208685288834191128150522",
                        "1"
                      ],
                      "pi_b": [
                        [
                          "9594440926911581241287727225722301982109644997256682324805944553313524634946",
                          "11565295827744962873774617627414137749955160085134551278427430722206524945299"
                        ],
                        [
                          "1479675336008373946106127040434847730831463379463342980782844960716119618140",
                          "11662034923894778106533052358864242035782777137376050474667036755873654802737"
                        ],
                        [
                          "1",
                          "0"
                        ]
                      ],
                      "pi_c": [
                        "14683991008366759908148689108245984383879186891268433456140944765595294225829",
                        "1094953752304781461119386460234892845707396369911231281129554885878524790859",
                        "1"
                      ],
                      "protocol": "groth16",
                      "curve": "bn128"
                    },
                    "pub_signals": [
                      "1",
                      "24082793358012584608174579977337611999996213347949865794732459169602409218",
                      "11308706860893816827371066764962337889424544939857771213011409856915723265787",
                      "1722589673",
                      "0",
                      "0"
                    ],
                    "id": 1722589673,
                    "circuitId": "credentialAtomicQuerySigV2"
                  }
                ]
              }
            }
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "object",
            "properties": {
              "createdAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp when this proof response was received."
              },
              "updatedAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp of the most recent update."
              },
              "proofExchangeId": {
                "type": "string",
                "format": "uuid",
                "description": "UUID of the proof exchange this response belongs to."
              },
              "isVerified": {
                "type": "boolean",
                "description": "Whether this ZK proof passed cryptographic verification."
              },
              "presentationId": {
                "type": "string",
                "format": "uuid",
                "description": "Unique identifier for this presentation response."
              },
              "response": {
                "type": "object",
                "description": "Full Iden3comm authorization response submitted by the holder's wallet.",
                "properties": {
                  "id": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Unique message ID."
                  },
                  "typ": {
                    "type": "string",
                    "description": "Iden3comm ZK JSON content type."
                  },
                  "type": {
                    "type": "string",
                    "description": "Iden3comm protocol message type URI."
                  },
                  "thid": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Thread ID correlating this response to the proof request."
                  },
                  "from": {
                    "type": "string",
                    "description": "Holder's `did:iden3:polygon:amoy` DID."
                  },
                  "to": {
                    "type": "string",
                    "description": "Verifier's `did:iden3:polygon:amoy` DID."
                  },
                  "body": {
                    "type": "object",
                    "properties": {
                      "did_doc": {
                        "type": "object",
                        "description": "Holder's DID document."
                      },
                      "message": {
                        "type": "string",
                        "nullable": true,
                        "description": "Optional message from the holder."
                      },
                      "scope": {
                        "type": "array",
                        "description": "Groth16 ZK proof objects for each scope in the original request.",
                        "items": {
                          "type": "object",
                          "properties": {
                            "proof": {
                              "type": "object",
                              "description": "Groth16 ZK proof.",
                              "properties": {
                                "pi_a": {
                                  "type": "array",
                                  "items": {
                                    "type": "string"
                                  },
                                  "description": "G1 point A."
                                },
                                "pi_b": {
                                  "type": "array",
                                  "items": {
                                    "type": "array",
                                    "items": {
                                      "type": "string"
                                    }
                                  },
                                  "description": "G2 point B."
                                },
                                "pi_c": {
                                  "type": "array",
                                  "items": {
                                    "type": "string"
                                  },
                                  "description": "G1 point C."
                                },
                                "protocol": {
                                  "type": "string",
                                  "enum": [
                                    "groth16"
                                  ],
                                  "description": "ZK proof protocol."
                                },
                                "curve": {
                                  "type": "string",
                                  "enum": [
                                    "bn128"
                                  ],
                                  "description": "Elliptic curve."
                                }
                              }
                            },
                            "pub_signals": {
                              "type": "array",
                              "items": {
                                "type": "string"
                              },
                              "description": "Public signals for proof verification."
                            },
                            "id": {
                              "type": "number",
                              "description": "Scope ID matching the original request."
                            },
                            "circuitId": {
                              "type": "string",
                              "enum": [
                                "credentialAtomicQuerySigV2"
                              ],
                              "description": "Iden3 ZK circuit."
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "GetProofResponseByProofIdResponse": {
        "title": "Get Proof Responses By Proof Exchange ID",
        "type": "object",
        "description": "Returned when listing all ZK proof responses associated with a specific `proofExchangeId`.",
        "example": {
          "success": true,
          "response": [
            {
              "createdAt": "2024-08-02T11:38:54.237Z",
              "updatedAt": "2024-08-02T11:38:54.237Z",
              "proofExchangeId": "acd42bba-891b-4577-9218-a51ce3f67e37",
              "isVerified": true,
              "presentationId": "d78c9b23-427e-402c-a8d6-25bbee602597"
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "array",
            "description": "All ZK proof response records for the specified proof exchange.",
            "items": {
              "type": "object",
              "properties": {
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp when this response was received."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent update."
                },
                "proofExchangeId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the proof exchange this response belongs to."
                },
                "isVerified": {
                  "type": "boolean",
                  "description": "Whether this ZK proof passed cryptographic verification."
                },
                "presentationId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Unique identifier for this presentation response."
                }
              }
            }
          }
        }
      },
      "GetAllCredentialsResponse": {
        "title": "Get All Credentials Response",
        "type": "object",
        "description": "Returned when listing all credential exchange records for the organization.",
        "example": {
          "success": true,
          "response": [
            {
              "credentialExchangeId": "cf37f0fd-47a0-4f50-869f-b162c61a7270",
              "credentialType": "jsonld-sig",
              "state": "done",
              "revoked": false,
              "createdAt": "2024-08-05T10:58:05.907Z",
              "updatedAt": "2024-08-05T10:58:52.617Z"
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "array",
            "description": "All credential exchange records for the organization.",
            "items": {
              "type": "object",
              "properties": {
                "credentialExchangeId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Hovi-assigned UUID for this credential exchange session."
                },
                "credentialType": {
                  "type": "string",
                  "enum": [
                    "jsonld-sig"
                  ],
                  "description": "Polygon-specific credential proof type. `jsonld-sig` — JSON-LD credential with Iden3 BJJSignature2021 proof."
                },
                "state": {
                  "type": "string",
                  "enum": [
                    "pending",
                    "done",
                    "abandoned"
                  ],
                  "description": "Credential exchange state. `done` — credential successfully issued and claimed by the holder."
                },
                "revoked": {
                  "type": "boolean",
                  "description": "Whether this credential has been revoked via the Iden3 Reverse Sparse Merkle Tree."
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp when this credential exchange was created."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent update."
                }
              }
            }
          }
        }
      },
      "GetCredentialResponse": {
        "title": "Get Credential Response",
        "type": "object",
        "description": "Returned when retrieving a specific credential exchange record by ID. When `state` is `done`, includes the full JSON-LD Verifiable Credential with Iden3 BJJSignature2021 proof, `credentialOfferUrl`, and `credentialOfferUri`.",
        "example": {
          "success": true,
          "response": {
            "credentialExchangeId": "cf37f0fd-47a0-4f50-869f-b162c61a7270",
            "credentialType": "jsonld-sig",
            "state": "done",
            "revoked": false,
            "requestType": "credential_exchange_request",
            "createdAt": "2024-08-05T10:58:05.907Z",
            "updatedAt": "2024-08-05T10:58:52.617Z",
            "credentialOfferUrl": "https://hovi.id/credential?data=eyJ1cmkiOiJpZGVuM2NvbW06Ly8...(truncated)",
            "credentialOfferUri": "iden3comm://?i_m=eyJpZCI6ImNmMzdmMGZkLTQ3YTAtNGY1MC04NjlmLWIxNjJjNjFhNzI3MCIsInRoaWQiOiJjZjM3ZjBmZC00N2EwLTRmNTAtODY5Zi1iMTYyYzYxYTcyNzAi...(truncated)",
            "credential": {
              "id": "urn:d5052970-901b-4693-a920-e41b4f1da749",
              "@context": [
                "https://www.w3.org/2018/credentials/v1",
                "https://schema.iden3.io/core/jsonld/iden3proofs.jsonld",
                "https://hovi.id/schemas/QmPxUiou4B8A5ee8udcfY1GUxU4CehTi8ZtuSh1wivhqmx"
              ],
              "type": [
                "VerifiableCredential",
                "University Degree Record"
              ],
              "credentialSubject": {
                "university": {
                  "batch": {
                    "passingYear": 2021
                  },
                  "branch": "KHI"
                },
                "fullName": "John Doe",
                "id": "did:iden3:polygon:amoy:2qWFZnE6b4NQRmWpeVAaHwMGYv2ccYNoLDakLX1LiT",
                "type": "University Degree Record"
              },
              "issuer": "did:iden3:polygon:amoy:2qQSaniB8hK6VRqwJVy5ch56JfYNAGFXKzKj81nQkk",
              "issuanceDate": "2024-08-05T10:57:54.845Z",
              "expirationDate": null,
              "credentialSchema": {
                "id": "https://hovi.id/schemas/QmRF7nnhYTsWu8sqA2jeLWbWP9LuuARS9RrWsL2akvwD7v",
                "type": "JsonSchema2023"
              },
              "credentialStatus": {
                "id": "https://rhs-staging.polygonid.me/node?state=cd83bd788807c4ec304cc17b6b773b6ad4a68ad0ca6244ecaa0bf60f2abe1b19",
                "type": "Iden3ReverseSparseMerkleTreeProof",
                "revocationNonce": 4215561986
              },
              "proof": [
                {
                  "type": "BJJSignature2021",
                  "issuerData": {
                    "id": "did:iden3:polygon:amoy:2qQSaniB8hK6VRqwJVy5ch56JfYNAGFXKzKj81nQkk",
                    "state": {
                      "rootOfRoots": "0000000000000000000000000000000000000000000000000000000000000000",
                      "revocationTreeRoot": "0000000000000000000000000000000000000000000000000000000000000000",
                      "claimsTreeRoot": "bedcfe8dac6fb708f2567023b9703e2c404894ce362e98b78540fffb73eb0908",
                      "value": "cd83bd788807c4ec304cc17b6b773b6ad4a68ad0ca6244ecaa0bf60f2abe1b19"
                    },
                    "mtp": {
                      "existence": true,
                      "siblings": [],
                      "nodeAux": null
                    },
                    "authCoreClaim": "cca3371a6cb1b715004407e325bd993c...(truncated)",
                    "credentialStatus": {
                      "id": "https://rhs-staging.polygonid.me/node?state=cd83bd788807c4ec304cc17b6b773b6ad4a68ad0ca6244ecaa0bf60f2abe1b19",
                      "type": "Iden3ReverseSparseMerkleTreeProof",
                      "revocationNonce": 0
                    }
                  },
                  "coreClaim": "58aa9e5a86a0c14d8bca91d04c08dc30...(truncated)",
                  "signature": "cb30f31a2bcec895ba7d4c70df1eaf81588c99d6ae09c3b64ce67c8239aa8c8f...(truncated)"
                }
              ]
            }
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "object",
            "properties": {
              "credentialExchangeId": {
                "type": "string",
                "format": "uuid",
                "description": "Unique identifier for this credential exchange session."
              },
              "credentialType": {
                "type": "string",
                "enum": [
                  "jsonld-sig"
                ],
                "description": "Polygon-specific credential proof type."
              },
              "state": {
                "type": "string",
                "enum": [
                  "pending",
                  "done",
                  "abandoned"
                ],
                "description": "Credential exchange state."
              },
              "revoked": {
                "type": "boolean",
                "description": "Whether this credential has been revoked via the Iden3 Reverse Sparse Merkle Tree."
              },
              "requestType": {
                "type": "string",
                "enum": [
                  "credential_exchange_request",
                  "presentation_exchange_request",
                  "did_exchange"
                ],
                "description": "Type of Iden3comm exchange that initiated this credential offer."
              },
              "createdAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp when this credential exchange was created."
              },
              "updatedAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp of the most recent update."
              },
              "credentialOfferUrl": {
                "type": "string",
                "format": "url",
                "description": "Hovi universal app link encapsulating the credential offer for mobile wallet deep linking."
              },
              "credentialOfferUri": {
                "type": "string",
                "description": "Iden3comm deep-link URI (`iden3comm://?i_m=...`) for wallet QR scanning to claim the credential."
              },
              "credential": {
                "type": "object",
                "description": "The issued W3C JSON-LD Verifiable Credential with Iden3 BJJSignature2021 proof. Present when `state` is `done`.",
                "properties": {
                  "id": {
                    "type": "string",
                    "description": "Unique URN identifier for this credential instance (e.g., `urn:d5052970-901b-4693-a920-e41b4f1da749`)."
                  },
                  "@context": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "JSON-LD `@context` URLs. Includes W3C VC base context, Iden3 proofs context, and the IPFS-hosted schema context."
                  },
                  "type": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "Credential type array (e.g., `[\"VerifiableCredential\", \"University Degree Record\"]`)."
                  },
                  "credentialSubject": {
                    "type": "object",
                    "description": "Claim values embedded in the credential. The `id` field holds the holder's `did:iden3:polygon:amoy` DID."
                  },
                  "issuer": {
                    "type": "string",
                    "description": "Issuer's `did:iden3:polygon:amoy` DID."
                  },
                  "issuanceDate": {
                    "type": "string",
                    "format": "date-time",
                    "description": "ISO 8601 timestamp of when this credential was issued."
                  },
                  "expirationDate": {
                    "type": "string",
                    "format": "date-time",
                    "nullable": true,
                    "description": "ISO 8601 expiry date. `null` if the credential does not expire."
                  },
                  "credentialSchema": {
                    "type": "object",
                    "description": "Reference to the JSON schema document for this credential type.",
                    "properties": {
                      "id": {
                        "type": "string",
                        "format": "url",
                        "description": "IPFS-hosted URL of the JSON schema document."
                      },
                      "type": {
                        "type": "string",
                        "enum": [
                          "JsonSchema2023"
                        ],
                        "description": "Schema type identifier."
                      }
                    }
                  },
                  "credentialStatus": {
                    "type": "object",
                    "description": "Iden3 revocation status endpoint for this credential.",
                    "properties": {
                      "id": {
                        "type": "string",
                        "format": "url",
                        "description": "Polygon ID Reverse Hash Service URL for revocation state lookup."
                      },
                      "type": {
                        "type": "string",
                        "enum": [
                          "Iden3ReverseSparseMerkleTreeProof"
                        ],
                        "description": "Iden3 revocation proof type."
                      },
                      "revocationNonce": {
                        "type": "number",
                        "description": "Unique nonce for this credential in the issuer's Sparse Merkle Tree."
                      }
                    }
                  },
                  "proof": {
                    "type": "array",
                    "description": "Cryptographic proof array. Contains one BJJSignature2021 proof.",
                    "items": {
                      "type": "object",
                      "properties": {
                        "type": {
                          "type": "string",
                          "enum": [
                            "BJJSignature2021"
                          ],
                          "description": "Iden3 Baby JubJub signature proof type."
                        },
                        "issuerData": {
                          "type": "object",
                          "description": "Issuer's identity state data at the time of issuance.",
                          "properties": {
                            "id": {
                              "type": "string",
                              "description": "Issuer's `did:iden3:polygon:amoy` DID."
                            },
                            "state": {
                              "type": "object",
                              "description": "Issuer's identity state tree roots at issuance time.",
                              "properties": {
                                "rootOfRoots": {
                                  "type": "string",
                                  "description": "Root of roots tree root hash."
                                },
                                "revocationTreeRoot": {
                                  "type": "string",
                                  "description": "Revocation tree root hash."
                                },
                                "claimsTreeRoot": {
                                  "type": "string",
                                  "description": "Claims tree root hash."
                                },
                                "value": {
                                  "type": "string",
                                  "description": "Composite identity state hash."
                                }
                              }
                            },
                            "mtp": {
                              "type": "object",
                              "description": "Merkle Tree Proof of the issuer state.",
                              "properties": {
                                "existence": {
                                  "type": "boolean",
                                  "description": "Whether the leaf exists in the tree."
                                },
                                "siblings": {
                                  "type": "array",
                                  "items": {
                                    "type": "string"
                                  },
                                  "description": "Sibling nodes for the MTP path."
                                },
                                "nodeAux": {
                                  "type": "object",
                                  "nullable": true,
                                  "description": "Auxiliary node data for non-existence proofs."
                                }
                              }
                            },
                            "authCoreClaim": {
                              "type": "string",
                              "description": "Hex-encoded issuer auth core claim used for BJJSignature2021 verification."
                            },
                            "credentialStatus": {
                              "type": "object",
                              "description": "Issuer's own credential status reference.",
                              "properties": {
                                "id": {
                                  "type": "string",
                                  "format": "url",
                                  "description": "Polygon ID Reverse Hash Service URL."
                                },
                                "type": {
                                  "type": "string",
                                  "enum": [
                                    "Iden3ReverseSparseMerkleTreeProof"
                                  ],
                                  "description": "Iden3 revocation proof type."
                                },
                                "revocationNonce": {
                                  "type": "number",
                                  "description": "Revocation nonce for the issuer auth claim."
                                }
                              }
                            }
                          }
                        },
                        "coreClaim": {
                          "type": "string",
                          "description": "Hex-encoded Iden3 core claim — the canonical binary representation of the credential."
                        },
                        "signature": {
                          "type": "string",
                          "description": "Hex-encoded BJJSignature2021 signature over the core claim."
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "IssueJsonLdCredentialResponse": {
        "title": "Issue JSON-LD Credential Response",
        "type": "object",
        "description": "Returned after successfully issuing a JSON-LD Verifiable Credential via the Iden3 credential offer protocol. The holder claims the credential by scanning the `credentialOfferUri` (`iden3comm://`) or the `credentialOfferUrl` deep link with a Polygon ID-compatible wallet.",
        "example": {
          "success": true,
          "response": {
            "credentialExchangeId": "cf37f0fd-47a0-4f50-869f-b162c61a7270",
            "credentialType": "jsonld-sig",
            "credentialOfferUri": "iden3comm://?i_m=eyJpZCI6ImNmMzdmMGZkLTQ3YTAtNGY1MC04NjlmLWIxNjJjNjFhNzI3MCIsInRoaWQiOiJjZjM3ZjBmZC00N2EwLTRmNTAtODY5Zi1iMTYyYzYxYTcyNzAi...(truncated)",
            "credentialOfferUrl": "https://hovi.id/credential?data=eyJ1cmkiOiJpZGVuM2NvbW06Ly8...(truncated)",
            "createdAt": "2024-08-05T10:58:05.907Z",
            "updatedAt": "2024-08-05T10:58:05.907Z",
            "credentialOfferRequest": {
              "id": "cf37f0fd-47a0-4f50-869f-b162c61a7270",
              "thid": "cf37f0fd-47a0-4f50-869f-b162c61a7270",
              "typ": "application/iden3comm-plain-json",
              "type": "https://iden3-communication.io/credentials/1.0/offer",
              "from": "did:iden3:polygon:amoy:2qQSaniB8hK6VRqwJVy5ch56JfYNAGFXKzKj81nQkk",
              "to": "did:iden3:polygon:amoy:2qWFZnE6b4NQRmWpeVAaHwMGYv2ccYNoLDakLX1LiT",
              "body": {
                "url": "https://polygon-agent.hovi.id/credential/issue-credential/cf37f0fd-47a0-4f50-869f-b162c61a7270",
                "credentials": [
                  {
                    "id": "urn:d5052970-901b-4693-a920-e41b4f1da749",
                    "description": ""
                  }
                ]
              }
            },
            "credential": {
              "id": "urn:d5052970-901b-4693-a920-e41b4f1da749",
              "@context": [
                "https://www.w3.org/2018/credentials/v1",
                "https://schema.iden3.io/core/jsonld/iden3proofs.jsonld",
                "https://hovi.id/schemas/QmPxUiou4B8A5ee8udcfY1GUxU4CehTi8ZtuSh1wivhqmx"
              ],
              "type": [
                "VerifiableCredential",
                "University Degree Record"
              ],
              "credentialSubject": {
                "university": {
                  "batch": {
                    "passingYear": 2021
                  },
                  "branch": "KHI"
                },
                "fullName": "John Doe",
                "id": "did:iden3:polygon:amoy:2qWFZnE6b4NQRmWpeVAaHwMGYv2ccYNoLDakLX1LiT",
                "type": "University Degree Record"
              },
              "issuer": "did:iden3:polygon:amoy:2qQSaniB8hK6VRqwJVy5ch56JfYNAGFXKzKj81nQkk",
              "issuanceDate": "2024-08-05T10:57:54.845Z",
              "credentialSchema": {
                "id": "https://hovi.id/schemas/QmRF7nnhYTsWu8sqA2jeLWbWP9LuuARS9RrWsL2akvwD7v",
                "type": "JsonSchema2023"
              },
              "credentialStatus": {
                "id": "https://rhs-staging.polygonid.me/node?state=cd83bd788807c4ec304cc17b6b773b6ad4a68ad0ca6244ecaa0bf60f2abe1b19",
                "type": "Iden3ReverseSparseMerkleTreeProof",
                "revocationNonce": 4215561986
              },
              "proof": [
                {
                  "type": "BJJSignature2021",
                  "coreClaim": "58aa9e5a86a0c14d8bca91d04c08dc30...(truncated)",
                  "signature": "cb30f31a2bcec895ba7d4c70df1eaf81588c99d6ae09c3b64ce67c8239aa8c8f...(truncated)"
                }
              ]
            }
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the credential was successfully issued."
          },
          "response": {
            "type": "object",
            "properties": {
              "credentialExchangeId": {
                "type": "string",
                "format": "uuid",
                "description": "Hovi-assigned UUID for this credential exchange session."
              },
              "credentialType": {
                "type": "string",
                "enum": [
                  "jsonld-sig"
                ],
                "description": "Polygon-specific credential proof type."
              },
              "credentialOfferUri": {
                "type": "string",
                "description": "Iden3comm deep-link URI (`iden3comm://?i_m=...`) for wallet QR scanning to claim the credential."
              },
              "credentialOfferUrl": {
                "type": "string",
                "format": "url",
                "description": "Hovi universal app link encapsulating the credential offer for mobile wallet deep linking."
              },
              "createdAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp when this credential exchange was created."
              },
              "updatedAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp of the most recent update."
              },
              "credentialOfferRequest": {
                "type": "object",
                "description": "The Iden3comm credential offer message sent to the holder wallet.",
                "properties": {
                  "id": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Unique message ID of the credential offer."
                  },
                  "thid": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Thread ID for this credential exchange."
                  },
                  "typ": {
                    "type": "string",
                    "enum": [
                      "application/iden3comm-plain-json"
                    ],
                    "description": "Iden3comm content type."
                  },
                  "type": {
                    "type": "string",
                    "enum": [
                      "https://iden3-communication.io/credentials/1.0/offer"
                    ],
                    "description": "Iden3comm credential offer message type URI."
                  },
                  "from": {
                    "type": "string",
                    "description": "Issuer's `did:iden3:polygon:amoy` DID."
                  },
                  "to": {
                    "type": "string",
                    "description": "Holder's `did:iden3:polygon:amoy` DID."
                  },
                  "body": {
                    "type": "object",
                    "properties": {
                      "url": {
                        "type": "string",
                        "format": "url",
                        "description": "Polygon agent fetch URL the holder wallet calls to retrieve the signed credential."
                      },
                      "credentials": {
                        "type": "array",
                        "description": "Array of credential references included in this offer.",
                        "items": {
                          "type": "object",
                          "properties": {
                            "id": {
                              "type": "string",
                              "description": "URN identifier of the credential being offered."
                            },
                            "description": {
                              "type": "string",
                              "description": "Optional description of the offered credential."
                            }
                          }
                        }
                      }
                    }
                  }
                }
              },
              "credential": {
                "type": "object",
                "description": "The issued W3C JSON-LD Verifiable Credential with Iden3 BJJSignature2021 proof.",
                "properties": {
                  "id": {
                    "type": "string",
                    "description": "URN identifier for this credential instance."
                  },
                  "@context": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "JSON-LD `@context` URLs."
                  },
                  "type": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "Credential type array."
                  },
                  "credentialSubject": {
                    "type": "object",
                    "description": "Claim values and holder `id` (`did:iden3:polygon:amoy` DID)."
                  },
                  "issuer": {
                    "type": "string",
                    "description": "Issuer's `did:iden3:polygon:amoy` DID."
                  },
                  "issuanceDate": {
                    "type": "string",
                    "format": "date-time",
                    "description": "ISO 8601 issuance timestamp."
                  },
                  "credentialSchema": {
                    "type": "object",
                    "properties": {
                      "id": {
                        "type": "string",
                        "format": "url",
                        "description": "IPFS-hosted JSON schema URL."
                      },
                      "type": {
                        "type": "string",
                        "enum": [
                          "JsonSchema2023"
                        ],
                        "description": "Schema type identifier."
                      }
                    }
                  },
                  "credentialStatus": {
                    "type": "object",
                    "properties": {
                      "id": {
                        "type": "string",
                        "format": "url",
                        "description": "Polygon ID Reverse Hash Service URL for revocation state."
                      },
                      "type": {
                        "type": "string",
                        "enum": [
                          "Iden3ReverseSparseMerkleTreeProof"
                        ],
                        "description": "Iden3 revocation proof type."
                      },
                      "revocationNonce": {
                        "type": "number",
                        "description": "Revocation nonce for this credential."
                      }
                    }
                  },
                  "proof": {
                    "type": "array",
                    "description": "Iden3 BJJSignature2021 proof array.",
                    "items": {
                      "type": "object",
                      "properties": {
                        "type": {
                          "type": "string",
                          "enum": [
                            "BJJSignature2021"
                          ],
                          "description": "Baby JubJub signature proof type."
                        },
                        "coreClaim": {
                          "type": "string",
                          "description": "Hex-encoded Iden3 core claim."
                        },
                        "signature": {
                          "type": "string",
                          "description": "Hex-encoded BJJSignature2021 signature."
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "getConnectionBase64": {
        "title": "Get Connection Base64 Request Body",
        "type": "object",
        "description": "Request body for retrieving the Base64-encoded connection invitation payload by invitation ID.",
        "required": [
          "invitationId"
        ],
        "properties": {
          "invitationId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the connection invitation to retrieve.",
            "example": "e53e1006-5ba3-4656-b1b0-d154d2ec6f5d"
          }
        }
      },
      "deleteConnection": {
        "title": "Delete Connection Request Body",
        "type": "object",
        "description": "Request body for deleting a specific connection record.",
        "required": [
          "connectionId"
        ],
        "properties": {
          "connectionId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the connection to delete.",
            "example": "89c02ee6-c60f-4e2c-b762-45810a566376"
          }
        }
      },
      "createTenant": {
        "title": "Create Tenant Request Body",
        "type": "object",
        "description": "Request body for creating a new organization (tenant). Auto-provisions a `did:iden3:polygon:amoy` DID and optional webhook endpoints.",
        "required": [
          "name",
          "label",
          "secret"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "Human-readable name of the organization.",
            "example": "Acme Corp"
          },
          "label": {
            "type": "string",
            "description": "Short identifier label for this organization.",
            "example": "acme-corp"
          },
          "secret": {
            "type": "string",
            "description": "Secret passphrase for organization management operations (rotate key, delete).",
            "example": "acme-corp-secret"
          },
          "imageUrl": {
            "type": "string",
            "format": "url",
            "description": "Optional URL of the organization's logo image.",
            "example": "https://acme-corp.com/logo.png"
          },
          "webhooks": {
            "type": "array",
            "description": "Optional array of webhook URLs to register during tenant creation.",
            "items": {
              "type": "string",
              "format": "url"
            },
            "example": [
              "https://acme-corp.com/webhook1",
              "https://acme-corp.com/webhook2"
            ]
          }
        }
      },
      "updateTenant": {
        "title": "Update Tenant",
        "type": "object",
        "description": "The data required to update an organization's (tenant's) display settings. All fields are optional only the fields provided will be updated.",
        "example": {
          "label": "acme-corp-updated",
          "imageUrl": "https://new-acme-corp.com/new-logo.png"
        },
        "properties": {
          "label": {
            "type": "string",
            "example": "acme-corp-updated",
            "description": "Updated short slug label for the organization (shown in DIDComm connection invitations)."
          },
          "imageUrl": {
            "type": "string",
            "format": "url",
            "example": "https://new-acme-corp.com/new-logo.png",
            "description": "URL pointing to the organization logo (the image shown for this organization in the dashboard)."
          }
        }
      },
      "deleteTenant": {
        "title": "Delete Tenant Request Body",
        "type": "object",
        "description": "Request body for deleting an organization and all its associated resources. This action is irreversible.",
        "required": [
          "organizationSecret"
        ],
        "properties": {
          "organizationSecret": {
            "type": "string",
            "description": "Secret passphrase provided during tenant creation. Required to authorize deletion.",
            "example": "acme-corp-secret"
          }
        }
      },
      "rotateKey": {
        "title": "Rotate Access Token Request Body",
        "type": "object",
        "description": "Request body for rotating the organization's Ecosystem API Key. The previous token is immediately invalidated.",
        "required": [
          "accessToken",
          "organizationSecret"
        ],
        "properties": {
          "accessToken": {
            "type": "string",
            "description": "Current organization access token (JWT) to be rotated.",
            "example": "eyJhbGciOiJIUzI1NiJ9.ZXlKMFpXNWhiblJKWkNJNklt...(truncated)"
          },
          "organizationSecret": {
            "type": "string",
            "description": "Organization secret passphrase. Required to authorize token rotation.",
            "example": "acme-corp-secret"
          }
        }
      },
      "getWebhook": {
        "title": "Get Webhook Request Body",
        "type": "object",
        "description": "Request body for retrieving a specific webhook by ID.",
        "required": [
          "webhookId"
        ],
        "properties": {
          "webhookId": {
            "type": "string",
            "description": "Unique identifier of the webhook to retrieve.",
            "example": "7d3aae8bfbe4b8472511db2a957158e8"
          }
        }
      },
      "addWebhook": {
        "title": "Add Webhook Request Body",
        "type": "object",
        "description": "Creates a webhook endpoint for receiving Hovi event notifications. Hovi automatically generates a signing secret and returns it in the response. Store this secret securely and use it to verify incoming webhook requests. Each request includes `x-webhook-timestamp` and `x-webhook-signature`. The signature is generated using HMAC-SHA256 over `{timestamp}.{rawBody}`. See the Webhooks guide for complete verification instructions. [See more](https://docs.hovi.id/api-guide/business-wallet-api/webhooks)",
        "required": [
          "webhookUrl"
        ],
        "properties": {
          "webhookUrl": {
            "type": "string",
            "format": "url",
            "description": "Publicly accessible HTTP(S) endpoint URL that will receive Hovi event notification POST requests. Must respond with a 2xx status code within the timeout window.",
            "example": "https://acme-corp.com/webhook1"
          }
        },
        "example": {
          "webhookUrl": "https://acme-corp.com/webhook1"
        }
      },
      "deleteWebhook": {
        "title": "Delete Webhook Request Body",
        "type": "object",
        "description": "Request body for deregistering a webhook endpoint.",
        "required": [
          "webhookId"
        ],
        "properties": {
          "webhookId": {
            "type": "string",
            "description": "Unique identifier of the webhook to delete.",
            "example": "7d3aae8bfbe4b8472511db2a957158e8"
          }
        }
      },
      "rotateWebhookSecret": {
        "title": "Rotate Webhook Secret Request Body",
        "type": "object",
        "description": "Request body for rotating the signing secret of an existing webhook. A signing secret is generated automatically.",
        "required": [
          "webhookId"
        ],
        "properties": {
          "webhookId": {
            "type": "string",
            "description": "Unique identifier of the webhook whose secret should be rotated.",
            "example": "7d3aae8bfbe4b8472511db2a957158e8"
          }
        }
      },
      "RotateWebhookSecretResponse": {
        "title": "Rotate Webhook Secret Response",
        "type": "object",
        "description": "Returned after successfully rotating a webhook signing secret.",
        "example": {
          "success": true,
          "response": {
            "webhookId": "7d3aae8bfbe4b8472511db2a957158e8",
            "webhookSecret": "your-new-webhook-secret"
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "object",
            "properties": {
              "webhookId": {
                "type": "string",
                "description": "Unique identifier of the webhook."
              },
              "webhookSecret": {
                "type": "string",
                "description": "Newly generated webhook signing secret."
              }
            }
          }
        }
      },
      "createJsonLdCredentialTemplate": {
        "title": "Create JSON-LD Credential Template Request Body",
        "type": "object",
        "description": "Request body for creating a JSON-LD credential template. The schema context document is published to IPFS and the template is stored for use in Iden3 credential issuance flows. Attributes support primitive types (`string`, `integer`, `double`, `boolean`) and nested `object` types for structured claim hierarchies.",
        "required": [
          "name",
          "version",
          "description",
          "attributes",
          "schemaType",
          "privadoCredentialType"
        ],
        "properties": {
          "categoryId": {
            "type": "string",
            "format": "uuid",
            "description": "Optional industry or sector category UUID to classify this credential template within Hovi Studio (e.g., healthcare, education). If omitted, the template is created without a category.",
            "example": "9636b597-cbe2-492a-bf92-87641729e6e4"
          },
          "name": {
            "type": "string",
            "description": "Human-readable name of the credential template as it will appear in Hovi Studio and the holder's wallet (e.g., `\"Patient ID 2\"`).",
            "example": "Patient ID 2"
          },
          "version": {
            "type": "string",
            "description": "Semantic version string for this template (e.g., `\"1.0.1\"`). Each unique `name` and `version` combination results in a distinct schema context document published to IPFS. Increment the version to publish schema changes since published schemas are immutable.",
            "example": "1.0.1"
          },
          "image": {
            "type": "string",
            "format": "url",
            "description": "Optional URL of the credential card background image displayed in the holder's wallet when this credential is issued and stored.",
            "example": "https://acme-corp.com/patient.png"
          },
          "description": {
            "type": "string",
            "description": "Plain-text description of what this credential represents (e.g., `\"Patient ID Card\"`).",
            "example": "Patient ID Card"
          },
          "attributes": {
            "type": "array",
            "description": "Ordered list of `credentialSubject` claim field definitions for this JSON-LD credential template. Supports primitive types (`string`, `integer`, `double`, `boolean`) and structured `object` types with nested `attributes` for multi-level claim hierarchies (e.g., `address.street`, `organization.department.departmentName`).",
            "items": {
              "type": "object",
              "description": "A single claim field definition. Use `type: \"object\"` with a nested `attributes` array to define structured multi-level claim hierarchies.",
              "properties": {
                "name": {
                  "type": "string",
                  "maxLength": 50,
                  "description": "Programmatic field identifier used as the key in the JSON-LD `credentialSubject` (e.g., `\"fullName\"`, `\"postalCode\"`). Must be camelCase and unique within its parent attribute scope.",
                  "example": "fullName"
                },
                "type": {
                  "type": "string",
                  "enum": [
                    "string",
                    "integer",
                    "double",
                    "boolean",
                    "object"
                  ],
                  "description": "Data type of this claim field. `string` — plain text value. `integer` — whole number. `double` — floating-point number. `boolean` — true/false flag. `object` — structured nested claim; must include a child `attributes` array defining its sub-fields.",
                  "example": "string"
                },
                "label": {
                  "type": "string",
                  "maxLength": 100,
                  "description": "Human-readable display label for this claim field shown in the holder's wallet UI and Hovi Studio (e.g., `\"Full Name\"`, `\"Postal Code\"`).",
                  "example": "Full Name"
                },
                "description": {
                  "type": "string",
                  "maxLength": 200,
                  "description": "Semantic description of this claim field explaining what data it represents (e.g., `\"Full legal name\"`, `\"ZIP or postal code\"`).",
                  "example": "Full legal name"
                },
                "required": {
                  "type": "boolean",
                  "description": "Whether this claim field must be provided with a value during credential issuance. `true` — the field is mandatory and issuance will fail if omitted. `false` — the field is optional and may be left unpopulated.",
                  "example": true
                },
                "attributes": {
                  "type": "array",
                  "description": "Nested sub-claim definitions for `object`-type attributes. Required when `type` is `\"object\"`. Supports recursive nesting — sub-attributes may themselves be of `type: \"object\"` with their own `attributes` array (e.g., `organization.department.departmentName`).",
                  "items": {
                    "type": "object",
                    "description": "A nested sub-claim field definition following the same structure as a top-level attribute (`name`, `type`, `label`, `description`, `required`, and optionally a further nested `attributes` array for deeply nested object hierarchies)."
                  }
                }
              }
            }
          },
          "schemaType": {
            "type": "string",
            "description": "The JSON-LD `@type` value embedded in all credentials issued from this template (e.g., `\"Patient Record\"`). This value is encoded into the IPFS-published schema context document and becomes the credential's semantic type identifier used by verifiers during presentation validation.",
            "example": "Patient Record"
          },
          "credentialTheme": {
            "$ref": "#/components/schemas/CredentialTheme",
            "description": "Optional visual rendering theme for the credential card displayed in Polygon ID-compatible wallets. Defines the card title, description, text colors, background image, and logo. When omitted, the wallet renders the credential using default styling."
          },
          "privadoCredentialType": {
            "type": "string",
            "description": "The Polygon ecosystem credential type identifier for this template (e.g., `\"Patient Record\"`). Used by the Polygon network to categorize and route credentials within its ecosystem. Typically matches `schemaType` but is stored and referenced independently within the Polygon registry.",
            "example": "Patient Record"
          }
        }
      },
      "importJsonLdCredentialTemplate": {
        "title": "Import JSON-LD Credential Template Request Body",
        "type": "object",
        "description": "Request body for importing an existing JSON-LD credential template by referencing a publicly hosted schema URL.",
        "required": [
          "schemaUrl"
        ],
        "properties": {
          "categoryId": {
            "type": "string",
            "format": "uuid",
            "description": "Optional industry/sector category UUID for the imported template.",
            "example": "2e5f483f-8970-4c5e-baf7-991ff24c120d"
          },
          "schemaUrl": {
            "type": "string",
            "format": "url",
            "description": "Public URL of the JSON-LD schema document to import (e.g., IPFS gateway URL).",
            "example": "https://hovi.id/schemas/QmRF7nnhYTsWu8sqA2jeLWbWP9LuuARS9RrWsL2akvwD7v"
          },
          "image": {
            "type": "string",
            "format": "url",
            "description": "Optional URL of the credential card image displayed in the holder's wallet.",
            "example": "https://acme-corp.com/patient.png"
          }
        }
      },
      "getTemplateByCredentialTemplateId": {
        "title": "Get Credential Template By ID Request Body",
        "type": "object",
        "description": "Request body for retrieving a specific credential template by its UUID.",
        "required": [
          "credentialTemplateId"
        ],
        "properties": {
          "credentialTemplateId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the credential template to retrieve.",
            "example": "ae5717a4-7f04-46a2-bf42-591cd226a7e2"
          }
        }
      },
      "getConnectionById": {
        "title": "Get Connection By ID Request Body",
        "type": "object",
        "description": "Request body for retrieving a specific connection record by its UUID.",
        "required": [
          "connectionId"
        ],
        "properties": {
          "connectionId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the connection to retrieve.",
            "example": "89c02ee6-c60f-4e2c-b762-45810a566376"
          }
        }
      },
      "getConnectionsByInvitationId": {
        "title": "Get Connections By Invitation ID Request Body",
        "type": "object",
        "description": "Request body for listing all connection records associated with a specific invitation UUID.",
        "required": [
          "inviationId"
        ],
        "properties": {
          "inviationId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the invitation to query connections for.",
            "example": "e53e1006-5ba3-4656-b1b0-d154d2ec6f5d"
          }
        }
      },
      "createConnectionInvitation": {
        "title": "Create Connection Invitation Request Body",
        "type": "object",
        "description": "Request body for generating an Iden3comm connection invitation. The `invitationUri` (`iden3comm://`) is encoded into a QR code or deep link for a Polygon ID-compatible holder wallet to scan.",
        "required": [
          "label"
        ],
        "properties": {
          "label": {
            "type": "string",
            "description": "Human-readable label for this connection invitation.",
            "example": "Acme Corp Connection"
          },
          "alias": {
            "type": "string",
            "description": "Optional alias name for the connection.",
            "example": "acme-connection"
          },
          "autoAcceptConnection": {
            "type": "boolean",
            "description": "Whether to automatically accept incoming connection responses without manual approval.",
            "example": true
          },
          "multiUseInvitation": {
            "type": "boolean",
            "description": "`true` — reusable invitation; multiple wallets may connect. `false` — single-use, expires after first connection.",
            "example": false
          },
          "domain": {
            "type": "string",
            "description": "Optional domain name associated with this connection invitation.",
            "example": "xyz-domain.com"
          },
          "imageUrl": {
            "type": "string",
            "format": "url",
            "description": "Optional URL of an image displayed on the connection invitation screen.",
            "example": "https://acme-corp.com/connection.png"
          }
        }
      },
      "getCredentialById": {
        "title": "Get Credential By ID Request Body",
        "type": "object",
        "description": "Request body for retrieving a specific credential exchange record by its UUID.",
        "required": [
          "credentialExchangeId"
        ],
        "properties": {
          "credentialExchangeId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the credential exchange to retrieve.",
            "example": "cf37f0fd-47a0-4f50-869f-b162c61a7270"
          }
        }
      },
      "issueJsonLdCredential": {
        "title": "Issue JSON-LD Credential Request Body",
        "type": "object",
        "description": "Request body for issuing a JSON-LD Verifiable Credential to a holder via the Iden3 credential offer protocol. The holder claims the credential by scanning the `credentialOfferUri` with a Polygon ID-compatible wallet.",
        "required": [
          "connectionId",
          "credentialTemplateId",
          "credentialValues"
        ],
        "properties": {
          "connectionId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the established Iden3comm connection to the holder's wallet.",
            "example": "89c02ee6-c60f-4e2c-b762-45810a566376"
          },
          "credentialTemplateId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the credential template to use for issuance.",
            "example": "ae5717a4-7f04-46a2-bf42-591cd226a7e2"
          },
          "credentialValues": {
            "type": "object",
            "description": "Key-value pairs mapping claim field names (from the template) to their values. Supports nested objects.",
            "example": {
              "name": "John Doe",
              "age": "30"
            }
          },
          "comment": {
            "type": "string",
            "description": "Optional plain-text comment attached to the credential offer.",
            "example": "This is a comment"
          }
        }
      },
      "getTemplateByVerificationTemplateId": {
        "title": "Get Verification Template By ID Request Body",
        "type": "object",
        "description": "Request body for retrieving a specific verification template by its UUID.",
        "required": [
          "verificationTemplateId"
        ],
        "properties": {
          "verificationTemplateId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the verification template to retrieve.",
            "example": "796dbd9d-8b61-4180-b94d-df4a4e138378"
          }
        }
      },
      "createJsonLdVerificationTemplate": {
        "title": "Create JSON-LD Verification Template Request Body",
        "type": "object",
        "description": "Request body for creating a JSON-LD verification template. The `conditions` array maps to Iden3 `privadoProofScopes` — `credentialAtomicQuerySigV2` circuit conditions defining the ZK proof request.",
        "required": [
          "name",
          "version",
          "description"
        ],
        "properties": {
          "categoryId": {
            "type": "string",
            "format": "uuid",
            "description": "Optional industry/sector category UUID for this verification template.",
            "example": "9636b597-cbe2-492a-bf92-87641729e6e4"
          },
          "contextUrl": {
            "type": "string",
            "format": "url",
            "description": "Optional JSON-LD `@context` URL for the credential schema being verified (e.g., IPFS gateway URL).",
            "example": "https://hovi.id/schemas/QmPxUiou4B8A5ee8udcfY1GUxU4CehTi8ZtuSh1wivhqmx"
          },
          "name": {
            "type": "string",
            "description": "Human-readable name of the verification template.",
            "example": "Patient ID Verification"
          },
          "version": {
            "type": "string",
            "description": "Semantic version string for this template.",
            "example": "1.0.1"
          },
          "description": {
            "type": "string",
            "description": "Plain-text description of what this template verifies.",
            "example": "Patient ID verification template"
          },
          "image": {
            "type": "string",
            "format": "url",
            "description": "Optional URL of an image displayed on the proof request screen.",
            "example": "https://acme-corp.com/patient.png"
          },
          "conditions": {
            "type": "array",
            "description": "Proof condition array. Each condition maps to one Iden3 `privadoProofScope` — a `credentialAtomicQuerySigV2` circuit query defining the ZK proof requirement.",
            "items": {
              "type": "object",
              "properties": {
                "allowedIssuers": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  },
                  "description": "Accepted issuer DIDs. `[\"*\"]` accepts credentials from any issuer.",
                  "example": [
                    "*"
                  ]
                },
                "credentialSubject": {
                  "type": "object",
                  "description": "Iden3 query conditions on credential subject fields. Supports `$eq`, `$in`, `$gt`, `$lt`, `$gte`, `$lte` operators on dot-notation field paths (e.g., `university.batch.passingYear`).",
                  "example": {
                    "university.batch.passingYear": {
                      "$in": [
                        2000,
                        2021,
                        2022
                      ]
                    }
                  }
                }
              }
            },
            "example": [
              {
                "allowedIssuers": [
                  "*"
                ],
                "credentialSubject": {
                  "university.batch.passingYear": {
                    "$in": [
                      2000,
                      2021,
                      2022
                    ]
                  }
                }
              },
              {
                "allowedIssuers": [
                  "*"
                ],
                "credentialSubject": {
                  "fullName": {
                    "$eq": "John Doe"
                  }
                }
              }
            ]
          },
          "restrictions": {
            "type": "object",
            "description": "Optional restrictions narrowing the acceptable credential types for this verification template.",
            "properties": {
              "credentialTemplateId": {
                "type": "string",
                "format": "uuid",
                "description": "Optional UUID of a specific credential template to restrict verification to.",
                "example": "ae5717a4-7f04-46a2-bf42-591cd226a7e2"
              },
              "schemaType": {
                "type": "string",
                "description": "Optional JSON-LD `@type` value to restrict verification to (e.g., `\"Patient Record\"`).",
                "example": "Patient Record"
              }
            }
          }
        }
      },
      "getProofRequestById": {
        "title": "Get Proof Request By ID Request Body",
        "type": "object",
        "description": "Request body for retrieving a specific proof exchange record by its UUID.",
        "required": [
          "proofExchangeId"
        ],
        "properties": {
          "proofExchangeId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the proof exchange to retrieve.",
            "example": "acd42bba-891b-4577-9218-a51ce3f67e37"
          }
        }
      },
      "getProofResponseById": {
        "title": "Get Proof Response By Presentation ID Request Body",
        "type": "object",
        "description": "Request body for retrieving a specific ZK proof response by its presentation UUID.",
        "required": [
          "presentationId"
        ],
        "properties": {
          "presentationId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the presentation response to retrieve.",
            "example": "d78c9b23-427e-402c-a8d6-25bbee602597"
          }
        }
      },
      "sendProofRequest": {
        "title": "Send Proof Request Request Body",
        "type": "object",
        "description": "Request body for sending a Polygon proof request to a holder wallet. The `proofRequestUri` (`iden3comm://`) and `verificationUrl` are encoded into a QR code or deep link for the holder to scan and submit a ZK proof.",
        "required": [
          "verificationTemplateId"
        ],
        "properties": {
          "verificationTemplateId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the verification template defining the proof scopes for this request.",
            "example": "796dbd9d-8b61-4180-b94d-df4a4e138378"
          },
          "connectionId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the established Iden3comm connection to the holder's wallet.",
            "example": "89c02ee6-c60f-4e2c-b762-45810a566376"
          }
        }
      },
      "DeleteTemplateByVerificationTemplateId": {
        "title": "Delete Verification Template Request Body",
        "type": "object",
        "description": "Request body for deleting a verification template by its UUID.",
        "required": [
          "verificationTemplateId"
        ],
        "properties": {
          "verificationTemplateId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the verification template to delete.",
            "example": "9636b597-cbe2-492a-bf92-87641729e6e4"
          }
        }
      },
      "UpdateTemplateByVerificationTemplateId": {
        "title": "Update Verification Template Request Body",
        "type": "object",
        "description": "Request body for updating an existing verification template.",
        "required": [
          "verificationTemplateId"
        ],
        "properties": {
          "verificationTemplateId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the verification template to update.",
            "example": "796dbd9d-8b61-4180-b94d-df4a4e138378"
          },
          "categoryId": {
            "type": "string",
            "format": "uuid",
            "description": "Optional updated industry/sector category UUID.",
            "example": "9636b597-cbe2-492a-bf92-87641729e6e4"
          },
          "name": {
            "type": "string",
            "description": "Optional updated name.",
            "example": "Updated Verification Template Name"
          },
          "description": {
            "type": "string",
            "description": "Optional updated description.",
            "example": "Updated description"
          },
          "image": {
            "type": "string",
            "format": "url",
            "description": "Optional updated image URL.",
            "example": "https://acme-corp.com/updated-image.png"
          }
        }
      },
      "UpdateCredentialTemplate": {
        "title": "Update Credential Template Request Body",
        "type": "object",
        "description": "Request body for updating an existing credential template.",
        "required": [
          "credentialTemplateId"
        ],
        "properties": {
          "credentialTemplateId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the credential template to update.",
            "example": "9636b597-cbe2-492a-bf92-87641729e6e4"
          },
          "categoryId": {
            "type": "string",
            "format": "uuid",
            "description": "Optional updated industry/sector category UUID.",
            "example": "9636b597-cbe2-492a-bf92-87641729e6e4"
          },
          "image": {
            "type": "string",
            "format": "url",
            "description": "Optional updated credential card image URL.",
            "example": "https://brandslogos.com/wp-content/uploads/images/large/acme-logo.png"
          }
        }
      },
      "DeleteCredentialTemplate": {
        "title": "Delete Credential Template Request Body",
        "type": "object",
        "description": "Request body for deleting a credential template by its UUID.",
        "required": [
          "credentialTemplateId"
        ],
        "properties": {
          "credentialTemplateId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the credential template to delete.",
            "example": "9636b597-cbe2-492a-bf92-87641729e6e4"
          }
        }
      },
      "PolygonConnectionCompletedWebhook": {
        "type": "object",
        "required": [
          "invitationId",
          "connectionId",
          "state",
          "isVerified",
          "id",
          "typ",
          "type",
          "thid",
          "body",
          "from",
          "to"
        ],
        "properties": {
          "invitationId": {
            "type": "string",
            "format": "uuid"
          },
          "connectionId": {
            "type": "string",
            "format": "uuid"
          },
          "state": {
            "type": "string",
            "const": "completed"
          },
          "isVerified": {
            "type": "boolean"
          },
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "typ": {
            "type": "string"
          },
          "type": {
            "type": "string",
            "format": "uri"
          },
          "thid": {
            "type": "string",
            "format": "uuid"
          },
          "body": {
            "type": "object",
            "additionalProperties": true
          },
          "from": {
            "type": "string"
          },
          "to": {
            "type": "string"
          }
        }
      },
      "PolygonCredentialIssuedWebhook": {
        "type": "object",
        "required": [
          "credentialExchangeId",
          "state",
          "isIssued",
          "id",
          "thid",
          "type",
          "typ",
          "to",
          "from",
          "body"
        ],
        "properties": {
          "credentialExchangeId": {
            "type": "string",
            "format": "uuid"
          },
          "state": {
            "type": "string",
            "const": "done"
          },
          "isIssued": {
            "type": "boolean"
          },
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "thid": {
            "type": "string",
            "format": "uuid"
          },
          "type": {
            "type": "string",
            "format": "uri"
          },
          "typ": {
            "type": "string"
          },
          "to": {
            "type": "string"
          },
          "from": {
            "type": "string"
          },
          "body": {
            "type": "object",
            "required": [
              "credential"
            ],
            "properties": {
              "credential": {
                "type": "object",
                "additionalProperties": true
              }
            }
          }
        }
      },
      "PolygonPresentationVerifiedWebhook": {
        "type": "object",
        "required": [
          "proofExchangeId",
          "presentationId",
          "state",
          "isVerified",
          "id",
          "typ",
          "type",
          "thid",
          "body",
          "from",
          "to"
        ],
        "properties": {
          "proofExchangeId": {
            "type": "string",
            "format": "uuid"
          },
          "presentationId": {
            "type": "string",
            "format": "uuid"
          },
          "state": {
            "type": "string",
            "const": "done"
          },
          "isVerified": {
            "type": "boolean"
          },
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "typ": {
            "type": "string"
          },
          "type": {
            "type": "string",
            "format": "uri"
          },
          "thid": {
            "type": "string",
            "format": "uuid"
          },
          "body": {
            "type": "object",
            "additionalProperties": true
          },
          "from": {
            "type": "string"
          },
          "to": {
            "type": "string"
          }
        }
      }
    },
    "@schemas": {
      "CredentialAttribute": {},
      "CredentialTheme": {
        "title": "Credential Visual Theme",
        "type": "object",
        "description": "Visual rendering metadata for the JSON-LD credential card displayed in Polygon ID-compatible wallets.",
        "example": {
          "title": "Patient ID Card",
          "description": "Proof of admission in the hospital",
          "textColor": "#000000",
          "backgroundImageUrl": "https://static.vecteezy.com/system/resources/thumbnails/011/020/176/small/abstract-white-and-light-gray-wave-modern-soft-luxury-texture-with-smooth-and-clean-background-free-vector.jpg",
          "logoUrl": "https://1000logos.net/wp-content/uploads/2016/10/ACME-Logo-1981.png",
          "logoAlt": "Acme Corp"
        },
        "properties": {
          "title": {
            "type": "string",
            "description": "Display title shown on the credential card. If omitted, the credential-template name is used."
          },
          "description": {
            "type": "string",
            "description": "Short descriptive text shown on the credential card."
          },
          "textColor": {
            "type": "string",
            "example": "#000000",
            "default": "#000000",
            "description": "Hex color code for the card text overlay. If omitted, `#000000` is used."
          },
          "backgroundImageUrl": {
            "type": "string",
            "format": "url",
            "description": "URL of the credential card background image. If omitted, a standard background image may be used."
          },
          "logoUrl": {
            "type": "string",
            "format": "url",
            "description": "URL of the issuer's logo image. If both logo fields are omitted, the organization's logo may be used. Required when `logoAlt` is provided."
          },
          "logoAlt": {
            "type": "string",
            "description": "Accessibility alt-text for the logo image. If omitted when `logoUrl` is provided, the organization's display name is used."
          }
        }
      },
      "CreateJsonLdCredentialTemplateResponse": {
        "title": "Create JSON-LD Credential Template Response",
        "type": "object",
        "description": "Returned after successfully creating a JSON-LD credential template. The schema context document is published to IPFS and the template is stored in Hovi for use in Iden3 credential issuance flows.",
        "example": {
          "success": true,
          "response": {
            "credentialTemplateId": "01b8e82f-6596-432f-85fb-4e1025bbac35",
            "schemaId": "b18ba975-bd6f-44dc-b23c-9560d2030e7a",
            "ecosystemId": "1d6e0184-e137-4a3b-bbb0-1a39216321bc",
            "organizationId": "0db20e29-b535-41f4-bff6-e4b607f59a52",
            "name": "Patient ID",
            "version": "1.0.1",
            "description": "Patient ID Card",
            "type": "jsonld",
            "image": "https://acme-corp.com/patient.png",
            "attributes": [
              {
                "name": "name",
                "label": "Name",
                "type": "string",
                "description": "Name of the patient",
                "required": true
              },
              {
                "name": "age",
                "label": "Age",
                "type": "string",
                "description": "Age of the patient",
                "required": true
              }
            ],
            "schemaUrl": "https://hovi.id/schemas/bafkreidnsspsutlwmuqhckkesbfukldxvl22ihje4wtoxo7btiqzzlsqwy",
            "schemaContext": "https://hovi.id/schemas/bafkreiajlvdphn5d53gzo4z6k6qw7us6rnphlwtyujdufdrtzds3g5tduq",
            "schemaType": "Patient",
            "createdAt": "2025-02-27T16:28:14.826Z",
            "updatedAt": "2025-02-27T16:28:14.826Z"
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates whether the credential template was successfully created."
          },
          "response": {
            "type": "object",
            "properties": {
              "credentialTemplateId": {
                "type": "string",
                "format": "uuid",
                "description": "Hovi-assigned UUID for this credential template. Use when issuing credentials."
              },
              "schemaId": {
                "type": "string",
                "format": "uuid",
                "description": "Internal Hovi UUID for the JSON-LD schema record."
              },
              "ecosystemId": {
                "type": "string",
                "format": "uuid",
                "description": "UUID of the Hovi ecosystem this template belongs to."
              },
              "organizationId": {
                "type": "string",
                "format": "uuid",
                "description": "UUID of the organization that owns this template."
              },
              "name": {
                "type": "string",
                "description": "Human-readable template name."
              },
              "version": {
                "type": "string",
                "description": "Semantic version string for this template."
              },
              "description": {
                "type": "string",
                "description": "Plain-text description of the credential type."
              },
              "type": {
                "type": "string",
                "enum": [
                  "jsonld"
                ],
                "description": "Credential format. `jsonld` — W3C JSON-LD Verifiable Credential with Iden3-compatible proof."
              },
              "image": {
                "type": "string",
                "format": "url",
                "description": "URL of the credential card image in the holder's wallet."
              },
              "attributes": {
                "type": "array",
                "description": "JSON-LD `credentialSubject` claim definitions. Supports nested object attributes.",
                "items": {
                  "$ref": "#/components/schemas/CredentialAttribute"
                }
              },
              "schemaUrl": {
                "type": "string",
                "format": "url",
                "description": "IPFS-hosted URL of the JSON schema document for this credential type."
              },
              "schemaContext": {
                "type": "string",
                "format": "url",
                "description": "IPFS-hosted JSON-LD `@context` URL mapping credential fields to semantic IRIs."
              },
              "schemaType": {
                "type": "string",
                "description": "JSON-LD `@type` value embedded in issued credentials (e.g., `\"Patient\"`)."
              },
              "createdAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp when this template was created."
              },
              "updatedAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp of the most recent update."
              }
            }
          }
        }
      },
      "UpdateTenantResponse": {
        "title": "Update Tenant Response",
        "type": "object",
        "description": "Returned after successfully updating an organization's display settings.",
        "example": {
          "success": true
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the tenant update was successful."
          }
        }
      },
      "ImportJsonLdCredentialTemplateResponse": {
        "title": "Import JSON-LD Credential Template Response",
        "type": "object",
        "description": "Returned after successfully importing an existing JSON-LD credential template by referencing a publicly hosted schema URL.",
        "example": {
          "success": true,
          "response": {
            "credentialTemplateId": "7471bb29-e875-4462-996a-69b2379a5049",
            "schemaId": "ceff35e7-8625-40f3-a0f3-316784593e29",
            "ecosystemId": "c9ba491b-988f-481d-9c33-a5cc5aaff4ed",
            "organizationId": "99f009f6-aefa-4c13-bbe9-e5e314a64b1c",
            "categoryId": "2e5f483f-8970-4c5e-baf7-991ff24c120d",
            "name": "University Degree",
            "version": "2.0.2",
            "description": "University Degree credential template",
            "type": "jsonld",
            "image": "https://brandslogos.com/wp-content/uploads/images/large/acme-logo.png",
            "attributes": [
              {
                "name": "university",
                "type": "object",
                "label": "University title",
                "description": "name of the university",
                "required": true,
                "attributes": [
                  {
                    "name": "batch",
                    "type": "object",
                    "label": "Batch title",
                    "description": "batch of the student",
                    "required": true,
                    "attributes": [
                      {
                        "name": "passingYear",
                        "type": "integer",
                        "label": "PassingYear title",
                        "description": "passing year of the student",
                        "required": true
                      }
                    ]
                  },
                  {
                    "name": "branch",
                    "type": "string",
                    "label": "Branch",
                    "description": "branch of the university",
                    "required": true
                  }
                ]
              },
              {
                "name": "fullName",
                "type": "string",
                "label": "Full Name",
                "description": "full name of the student",
                "required": true
              }
            ],
            "schemaUrl": "https://hovi.id/schemas/QmRF7nnhYTsWu8sqA2jeLWbWP9LuuARS9RrWsL2akvwD7v",
            "schemaType": "University Degree",
            "createdAt": "2024-08-12T11:21:32.464Z",
            "updatedAt": "2024-08-12T11:21:32.464Z"
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "object",
            "properties": {
              "credentialTemplateId": {
                "type": "string",
                "format": "uuid",
                "description": "Hovi-assigned UUID for the imported credential template."
              },
              "schemaId": {
                "type": "string",
                "format": "uuid",
                "description": "Internal Hovi UUID for the JSON-LD schema record."
              },
              "ecosystemId": {
                "type": "string",
                "format": "uuid",
                "description": "UUID of the Hovi ecosystem this template belongs to."
              },
              "organizationId": {
                "type": "string",
                "format": "uuid",
                "description": "UUID of the organization that performed the import."
              },
              "categoryId": {
                "type": "string",
                "format": "uuid",
                "description": "Industry/sector category UUID."
              },
              "name": {
                "type": "string",
                "description": "Human-readable name of the imported credential template."
              },
              "version": {
                "type": "string",
                "description": "Version string of the imported template."
              },
              "description": {
                "type": "string",
                "description": "Plain-text description of the imported credential template."
              },
              "type": {
                "type": "string",
                "enum": [
                  "jsonld"
                ],
                "description": "Credential format of the imported template."
              },
              "image": {
                "type": "string",
                "format": "url",
                "description": "URL of the credential card image in the holder's wallet."
              },
              "attributes": {
                "type": "array",
                "description": "Claim fields derived from the imported JSON-LD schema. Supports nested object attributes.",
                "items": {
                  "$ref": "#/components/schemas/CredentialAttribute"
                }
              },
              "schemaUrl": {
                "type": "string",
                "format": "url",
                "description": "Public URL of the imported JSON-LD schema document."
              },
              "schemaType": {
                "type": "string",
                "description": "JSON-LD `@type` value from the imported schema."
              },
              "createdAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp when this import record was created."
              },
              "updatedAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp of the most recent update."
              }
            }
          }
        }
      },
      "GetCredentialTemplatesResponse": {
        "title": "Get Credential Templates Response",
        "type": "object",
        "description": "Returned when listing all JSON-LD credential templates belonging to an organization.",
        "example": {
          "success": true,
          "response": [
            {
              "credentialTemplateId": "ae5717a4-7f04-46a2-bf42-591cd226a7e2",
              "schemaId": "ee473b74-c97a-49f9-962e-eb84b493f644",
              "ecosystemId": "1d6e0184-e137-4a3b-bbb0-1a39216321bc",
              "organizationId": "de7e7ab5-109e-44d0-966d-78aa74d81ca7",
              "name": "Patient ID",
              "version": "1.0.1",
              "description": "Patient ID Card",
              "type": "jsonld",
              "image": "https://acme-corp.com/patient.png",
              "attributes": [
                {
                  "name": "name",
                  "label": "Name",
                  "type": "string",
                  "description": "Name of the patient",
                  "required": true
                },
                {
                  "name": "age",
                  "label": "Age",
                  "type": "string",
                  "description": "Age of the patient",
                  "required": true
                }
              ],
              "schemaUrl": "https://hovi.id/schemas/bafkreicqmxe3l6xraujo7ovdanrwxeh5q5uy32prku5ma2ziogofzsydya",
              "schemaContext": "https://hovi.id/schemas/bafkreigts7qmpygexrikxf3ypmm6tvb26plf2dlv744u2vzdlbdxm24ctm",
              "schemaType": "Patient",
              "privadoCredentialType": "jsonld-sig",
              "createdAt": "2024-11-12T13:22:36.153Z",
              "updatedAt": "2024-11-12T13:22:36.153Z"
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the listing was retrieved successfully."
          },
          "response": {
            "type": "array",
            "description": "Array of all JSON-LD credential template records for this organization.",
            "items": {
              "type": "object",
              "properties": {
                "credentialTemplateId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Hovi-assigned UUID for this credential template."
                },
                "schemaId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Internal Hovi UUID for the JSON-LD schema record."
                },
                "ecosystemId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the Hovi ecosystem this template belongs to."
                },
                "organizationId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the organization that owns this template."
                },
                "name": {
                  "type": "string",
                  "description": "Human-readable template name."
                },
                "version": {
                  "type": "string",
                  "description": "Semantic version string."
                },
                "description": {
                  "type": "string",
                  "description": "Plain-text description of the credential type."
                },
                "type": {
                  "type": "string",
                  "enum": [
                    "jsonld"
                  ],
                  "description": "Credential format."
                },
                "image": {
                  "type": "string",
                  "format": "url",
                  "description": "URL of the credential card image in the holder's wallet."
                },
                "attributes": {
                  "type": "array",
                  "description": "JSON-LD `credentialSubject` claim definitions.",
                  "items": {
                    "$ref": "#/components/schemas/CredentialAttribute"
                  }
                },
                "schemaUrl": {
                  "type": "string",
                  "format": "url",
                  "description": "IPFS-hosted JSON schema URL for this credential type."
                },
                "schemaContext": {
                  "type": "string",
                  "format": "url",
                  "description": "IPFS-hosted JSON-LD `@context` URL."
                },
                "schemaType": {
                  "type": "string",
                  "description": "JSON-LD `@type` value embedded in issued credentials."
                },
                "privadoCredentialType": {
                  "type": "string",
                  "enum": [
                    "jsonld-sig",
                    "jsonld-mtp"
                  ],
                  "description": "Polygon-specific credential proof type. `jsonld-sig` — JSON-LD credential with Iden3 BJJSignature2021 proof, or `jsonld-mtp` — JSON-LD credential with Merkle Tree Proof."
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp when this template was created."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent update."
                }
              }
            }
          }
        }
      },
      "GetVerificationTemplatesResponse": {
        "title": "Get Verification Templates Response",
        "type": "object",
        "description": "Returned when listing all JSON-LD verification templates belonging to an organization. Each template contains `privadoProofScopes` defining the Iden3 `credentialAtomicQuerySigV2` circuit conditions for the proof request.",
        "example": {
          "success": true,
          "response": [
            {
              "verificationTemplateId": "796dbd9d-8b61-4180-b94d-df4a4e138378",
              "ecosystemId": "259c9647-5f27-49a7-9762-42d9231709a2",
              "organizationId": "c7a3c4ae-63d4-41d8-9d17-0fb402d4a6fd",
              "categoryId": "9636b597-cbe2-492a-bf92-87641729e6e4",
              "name": "University Degree Verification",
              "image": "https://picsum.photos/200",
              "version": "2.0.8",
              "description": "University Degree verification template",
              "type": "jsonld",
              "credentialType": "jsonld-sig",
              "privadoProofScopes": [
                {
                  "circuitId": "credentialAtomicQuerySigV2",
                  "id": 1,
                  "query": {
                    "allowedIssuers": [
                      "*"
                    ],
                    "type": "University Degree Record",
                    "credentialSubject": {
                      "university.batch.passingYear": {
                        "$in": [
                          2000,
                          2021,
                          2022
                        ]
                      }
                    }
                  }
                },
                {
                  "circuitId": "credentialAtomicQuerySigV2",
                  "id": 2,
                  "query": {
                    "allowedIssuers": [
                      "*"
                    ],
                    "type": "University Degree Record",
                    "credentialSubject": {
                      "fullName": {
                        "$eq": "John Doe"
                      }
                    }
                  }
                }
              ],
              "createdAt": "2024-08-05T11:01:31.997Z",
              "updatedAt": "2024-08-05T11:01:31.997Z"
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the listing was retrieved successfully."
          },
          "response": {
            "type": "array",
            "description": "Array of all JSON-LD verification template records for this organization.",
            "items": {
              "type": "object",
              "properties": {
                "verificationTemplateId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Hovi-assigned UUID for this verification template."
                },
                "ecosystemId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the Hovi ecosystem this template belongs to."
                },
                "organizationId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the organization that owns this template."
                },
                "categoryId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Industry/sector category UUID."
                },
                "name": {
                  "type": "string",
                  "description": "Human-readable name of the verification template."
                },
                "image": {
                  "type": "string",
                  "format": "url",
                  "description": "URL of the image shown on the proof request screen."
                },
                "version": {
                  "type": "string",
                  "description": "Semantic version string."
                },
                "description": {
                  "type": "string",
                  "description": "Plain-text description of what this template checks."
                },
                "type": {
                  "type": "string",
                  "enum": [
                    "jsonld"
                  ],
                  "description": "Credential format this template targets."
                },
                "credentialType": {
                  "type": "string",
                  "enum": [
                    "jsonld-sig"
                  ],
                  "description": "Polygon-specific credential proof type this template targets."
                },
                "privadoProofScopes": {
                  "type": "array",
                  "description": "Polygon proof scope definitions — each scope maps to one Iden3 `credentialAtomicQuerySigV2` circuit query. Multiple scopes are AND-ed together.",
                  "items": {
                    "type": "object",
                    "properties": {
                      "circuitId": {
                        "type": "string",
                        "enum": [
                          "credentialAtomicQuerySigV2"
                        ],
                        "description": "Iden3 ZK circuit used to verify this scope (`credentialAtomicQuerySigV2` — Groth16 signature-based atomic query circuit)."
                      },
                      "id": {
                        "type": "number",
                        "description": "Numeric identifier for this scope within the proof request."
                      },
                      "query": {
                        "type": "object",
                        "description": "Iden3 proof query definition for this scope.",
                        "properties": {
                          "allowedIssuers": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            },
                            "description": "Accepted issuer DIDs. `[\"*\"]` accepts credentials from any issuer."
                          },
                          "type": {
                            "type": "string",
                            "description": "JSON-LD `@type` of the credential this scope targets."
                          },
                          "context": {
                            "type": "string",
                            "format": "url",
                            "description": "Optional JSON-LD `@context` URL for the credential schema."
                          },
                          "credentialSubject": {
                            "type": "object",
                            "description": "Iden3 query conditions on credential subject fields. Supports `$eq`, `$in`, `$gt`, `$lt`, `$gte`, `$lte` operators on dot-notation field paths."
                          }
                        }
                      }
                    }
                  }
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp when this template was created."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent update."
                }
              }
            }
          }
        }
      },
      "CreateJsonLdVerificationTemplateResponse": {
        "title": "Create JSON-LD Verification Template Response",
        "type": "object",
        "description": "Returned after successfully creating a JSON-LD verification template. The template defines Iden3 `credentialAtomicQuerySigV2` proof scopes used to generate Polygon-compatible proof requests.",
        "example": {
          "success": true,
          "response": {
            "verificationTemplateId": "796dbd9d-8b61-4180-b94d-df4a4e138378",
            "ecosystemId": "259c9647-5f27-49a7-9762-42d9231709a2",
            "organizationId": "c7a3c4ae-63d4-41d8-9d17-0fb402d4a6fd",
            "categoryId": "9636b597-cbe2-492a-bf92-87641729e6e4",
            "name": "University Degree Verification",
            "image": "https://picsum.photos/200",
            "version": "2.0.8",
            "description": "University Degree verification template",
            "type": "jsonld",
            "credentialType": "jsonld-sig",
            "privadoProofScopes": [
              {
                "circuitId": "credentialAtomicQuerySigV2",
                "id": 1,
                "query": {
                  "allowedIssuers": [
                    "*"
                  ],
                  "type": "University Degree Record",
                  "credentialSubject": {
                    "university.batch.passingYear": {
                      "$in": [
                        2000,
                        2021,
                        2022
                      ]
                    }
                  }
                }
              },
              {
                "circuitId": "credentialAtomicQuerySigV2",
                "id": 2,
                "query": {
                  "allowedIssuers": [
                    "*"
                  ],
                  "type": "University Degree Record",
                  "credentialSubject": {
                    "fullName": {
                      "$eq": "John Doe"
                    }
                  }
                }
              }
            ],
            "createdAt": "2024-08-05T11:01:31.997Z",
            "updatedAt": "2024-08-05T11:01:31.997Z"
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "object",
            "properties": {
              "verificationTemplateId": {
                "type": "string",
                "format": "uuid",
                "description": "Hovi-assigned UUID for the newly created verification template."
              },
              "ecosystemId": {
                "type": "string",
                "format": "uuid",
                "description": "UUID of the Hovi ecosystem this template belongs to."
              },
              "organizationId": {
                "type": "string",
                "format": "uuid",
                "description": "UUID of the organization that created this template."
              },
              "categoryId": {
                "type": "string",
                "format": "uuid",
                "description": "Industry/sector category UUID."
              },
              "name": {
                "type": "string",
                "description": "Human-readable name of the verification template."
              },
              "image": {
                "type": "string",
                "format": "url",
                "description": "URL of the image shown on the proof request screen."
              },
              "version": {
                "type": "string",
                "description": "Semantic version string."
              },
              "description": {
                "type": "string",
                "description": "Plain-text description of what this template checks."
              },
              "type": {
                "type": "string",
                "enum": [
                  "jsonld"
                ],
                "description": "Credential format this template targets."
              },
              "credentialType": {
                "type": "string",
                "enum": [
                  "jsonld-sig"
                ],
                "description": "Polygon-specific credential proof type."
              },
              "privadoProofScopes": {
                "type": "array",
                "description": "Polygon proof scope definitions — each maps to one Iden3 `credentialAtomicQuerySigV2` circuit query.",
                "items": {
                  "type": "object",
                  "properties": {
                    "circuitId": {
                      "type": "string",
                      "enum": [
                        "credentialAtomicQuerySigV2"
                      ],
                      "description": "Iden3 ZK circuit for this scope."
                    },
                    "id": {
                      "type": "number",
                      "description": "Numeric scope identifier within the proof request."
                    },
                    "query": {
                      "type": "object",
                      "description": "Iden3 proof query for this scope.",
                      "properties": {
                        "allowedIssuers": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "Accepted issuer DIDs. `[\"*\"]` accepts any issuer."
                        },
                        "type": {
                          "type": "string",
                          "description": "JSON-LD `@type` of the target credential."
                        },
                        "credentialSubject": {
                          "type": "object",
                          "description": "Query conditions on credential subject fields using Iden3 operators (`$eq`, `$in`, `$gt`, etc.)."
                        }
                      }
                    }
                  }
                }
              },
              "createdAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp when this template was created."
              },
              "updatedAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp of the most recent update."
              }
            }
          }
        }
      },
      "AddWebhookResponse": {
        "title": "Add Webhook Response",
        "type": "object",
        "description": "Returned after successfully registering a new webhook endpoint.",
        "example": {
          "success": true,
          "response": {
            "webhookId": "7d3aae8bfbe4b8472511db2a957158e8",
            "webhookUrl": "https://kindi10.requestcatcher.com",
            "webhookSecret": "4FME20TvYrxqTHJmjOvM1OG7_amYukdYbsT8MjQUN-s"
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "object",
            "properties": {
              "webhookId": {
                "type": "string",
                "description": "Unique hex identifier for this webhook registration."
              },
              "webhookUrl": {
                "type": "string",
                "format": "url",
                "description": "HTTP callback URL that Hovi POSTs event notification payloads to."
              },
              "webhookSecret": {
                "type": "string",
                "description": "Secret used to sign webhook payloads. Generated automatically."
              }
            }
          }
        }
      },
      "RemoveWebhookResponse": {
        "title": "Remove Webhook Response",
        "type": "object",
        "description": "Returned after successfully deregistering a webhook endpoint.",
        "example": {
          "success": true,
          "message": "Webhook with id 6d98b1a8-32d9-4bd3-bd31-c4fa364d18ff deleted successfully"
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the webhook was successfully removed."
          },
          "message": {
            "type": "string",
            "description": "Human-readable confirmation message."
          }
        }
      },
      "GetWebhooksResponse": {
        "title": "Get Webhooks Response",
        "type": "object",
        "description": "Returned when listing all registered webhook endpoints for an organization.",
        "example": {
          "success": true,
          "response": [
            {
              "webhookId": "305b56ab8064dfdd801d1697795e7ab0",
              "organizationId": "9def09fb-19a1-49b5-bda5-f1954c179b2d",
              "ecosystemId": "e6e31de2-83ad-4af9-8cd9-d9861b6ee5d5",
              "url": "https://kindi10.requestcatcher.com",
              "createdAt": "2024-06-21T06:31:26.415Z",
              "updatedAt": "2024-06-21T06:31:26.415Z"
            },
            {
              "webhookId": "0f8fad7f93e617ff0e548725678e81a8",
              "organizationId": "9def09fb-19a1-49b5-bda5-f1954c179b2d",
              "ecosystemId": "e6e31de2-83ad-4af9-8cd9-d9861b6ee5d5",
              "url": "https://kindi10.requestcatcher.com",
              "createdAt": "2024-06-21T06:31:26.487Z",
              "updatedAt": "2024-06-21T06:31:26.487Z"
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "array",
            "description": "All registered webhook endpoints for the organization.",
            "items": {
              "type": "object",
              "properties": {
                "webhookId": {
                  "type": "string",
                  "description": "Unique hex identifier for this webhook registration."
                },
                "organizationId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the organization that registered this webhook."
                },
                "ecosystemId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the Hovi ecosystem this webhook belongs to."
                },
                "url": {
                  "type": "string",
                  "format": "url",
                  "description": "HTTP callback URL receiving Hovi event notification POSTs."
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp when this webhook was registered."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent update."
                }
              }
            }
          }
        }
      },
      "CreateTenantResponse": {
        "title": "Create Tenant Response",
        "type": "object",
        "description": "Returned after successfully creating a new organization (tenant). The response includes the organization identifiers, access token, display settings, the auto-provisioned `did:iden3:polygon:amoy` DID with its private key for credential signing, and any configured webhook endpoints.",
        "example": {
          "success": true,
          "response": {
            "organizationId": "1abbaba4-8604-4ef8-a01f-fa788a771795",
            "tenantId": "1abbaba4-8604-4ef8-a01f-fa788a771795",
            "setting": {
              "organizationName": "Acme Corp",
              "defaultLabel": "acme-corp",
              "image": "https://acme-corp.com/logo.png",
              "id": "1abbaba4-8604-4ef8-a01f-fa788a771795"
            },
            "accessToken": "eyJhbGciOiJIUzI1NiJ9.ZXlKMFpXNWhiblJKWkNJNklqRmhZbUpoWW1FMExUZzJNRFF0TkdWbU9DMWhNREZtTFdaaE15NjRiRzQ4WVRjM01UYzVOVElzSW1saGRDSTZNVGMzT0RRNk5UQXpPSDA9.zwwmiaG5xwWz0ZmPNo4KOoQo8LwMZE3oerFZkoK8VVk",
            "dids": [
              {
                "did": "did:iden3:polygon:amoy:xDmMUg1z43pTTy6u2W8wSsq65arWgEwVdvJiDTwQG",
                "method": "iden3",
                "privateKey": "f6vUOXNZM8aCdPLB8w51oUhDfJ6nQotB"
              }
            ],
            "webhooks": [
              {
                "webhookUrl": "https://acme-corp.com/webhook1",
                "webhookId": "96438837-9a60-42c5-b7de-95ff4ed7ec88"
              },
              {
                "webhookUrl": "https://acme-corp.com/webhook2",
                "webhookId": "e8db92af-aa89-463e-b8c9-d9d617971461"
              }
            ]
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates whether the organization was successfully created. Returns `true` on success, `false` if creation failed (e.g., duplicate organization name, quota exceeded, or invalid configuration)."
          },
          "response": {
            "type": "object",
            "description": "The newly created organization record including its identifiers, credentials, DID, and registered webhooks.",
            "properties": {
              "organizationId": {
                "type": "string",
                "format": "uuid",
                "description": "Hovi-assigned UUID uniquely identifying this organization. Shares the same value as `tenantId` — both fields refer to the same entity and can be used interchangeably when referencing this organization across Hovi APIs."
              },
              "tenantId": {
                "type": "string",
                "format": "uuid",
                "description": "Hovi-assigned UUID for this organization's tenant record. Shares the same value as `organizationId` — both fields refer to the same entity. Use this as the `x-organization-id` header value in subsequent API requests."
              },
              "setting": {
                "type": "object",
                "description": "Display and configuration settings for this organization as stored in Hovi Studio.",
                "properties": {
                  "id": {
                    "type": "string",
                    "format": "uuid",
                    "description": "UUID of this settings record — matches `organizationId` and `tenantId` for this organization."
                  },
                  "organizationName": {
                    "type": "string",
                    "description": "The full display name of the organization as it appears in Hovi Studio and in credential metadata shown in the holder's wallet (e.g., `\"Acme Corp\"`)."
                  },
                  "defaultLabel": {
                    "type": "string",
                    "description": "A URL-safe slug derived from the organization name, used as the default label for DIDComm connection invitations and internal routing (e.g., `\"acme-corp\"`)."
                  },
                  "image": {
                    "type": "string",
                    "format": "url",
                    "description": "URL of the organization's logo image displayed in Hovi Studio and in the holder's wallet during connection and credential acceptance flows."
                  }
                }
              },
              "accessToken": {
                "type": "string",
                "description": "Organization-scoped JWT used to authenticate all subsequent API requests for this organization. Pass this as the `Bearer` token in the `Authorization` header. **Store securely and treat as a secret** — this token grants full access to all operations for this organization."
              },
              "dids": {
                "type": "array",
                "description": "List of DIDs auto-provisioned for this organization at creation time. Each entry represents a cryptographic identity anchored on the Polygon Amoy testnet used for credential signing and DIDComm communication.",
                "items": {
                  "type": "object",
                  "properties": {
                    "did": {
                      "type": "string",
                      "description": "The fully-qualified `did:iden3:polygon:amoy` DID string for this organization (e.g., `did:iden3:polygon:amoy:<identifier>`). This DID is used as the issuer identifier when signing credentials and as the organization's cryptographic identity on the Polygon Amoy network."
                    },
                    "method": {
                      "type": "string",
                      "enum": [
                        "iden3"
                      ],
                      "description": "The DID method used for this organization's identifier. `iden3` indicates this DID is anchored on the Polygon Amoy network using the Iden3 protocol."
                    },
                    "privateKey": {
                      "type": "string",
                      "description": "The private key material for this DID used to sign credentials and authenticate DIDComm messages. **Store securely and never expose** — loss of this key means loss of signing capability for this DID, and exposure compromises the integrity of all credentials issued by this organization."
                    }
                  }
                }
              },
              "webhooks": {
                "type": "array",
                "description": "List of webhook endpoints registered for this organization at creation time. Each entry represents an HTTP callback URL that will receive real-time event notifications (e.g., credential state changes, connection updates) as they occur on this organization's agent.",
                "items": {
                  "type": "object",
                  "properties": {
                    "webhookId": {
                      "type": "string",
                      "format": "uuid",
                      "description": "Server-assigned UUID uniquely identifying this webhook registration. Use this ID to update or remove the webhook endpoint in subsequent API calls."
                    },
                    "webhookUrl": {
                      "type": "string",
                      "format": "url",
                      "description": "The publicly reachable HTTP callback URL that will receive POST requests containing event payloads when activity occurs on this organization's agent (e.g., `https://acme-corp.com/webhook1`)."
                    }
                  }
                }
              }
            }
          }
        }
      },
      "RotateTenantAccessTokenResponse": {
        "title": "Rotate Tenant Access Token Response",
        "type": "object",
        "description": "Returned after successfully rotating the organization's Ecosystem API Key. The previous token is immediately invalidated.",
        "example": {
          "success": true,
          "response": {
            "accessToken": "eyJhbGciOiJIUzI1NiJ9.ZXlKMFpxNWhiblJKWkNJNklqZGhORFpsT1RneUxUUTVNemt0TkRobVpDMDRabUl6TFRNeVpEaGxaVEV4T1RZMk5TSXNJbWxoZENJNk1UY3lNamcyTkRVMU5uMD0.VUejpKgvZWDHrO1SogCxixRM1S4ykQAHqpIu0XmrTvI"
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the token rotation was successful."
          },
          "response": {
            "type": "object",
            "properties": {
              "accessToken": {
                "type": "string",
                "description": "Newly generated Ecosystem API Key (JWT). Replace the previous token in all API clients immediately."
              }
            }
          }
        }
      },
      "DeleteTenantReponse": {
        "title": "Delete Tenant Response",
        "type": "object",
        "description": "Returned after successfully deleting an organization and all its associated resources. This action is irreversible.",
        "example": {
          "success": true
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the tenant was successfully deleted."
          }
        }
      },
      "GetTenantsResponse": {
        "title": "Get Tenants Response",
        "type": "object",
        "description": "Returned when listing all organizations within the Hovi ecosystem, including archived ones. Each item includes a `status` of `active` or `archived`. Optional `organizationId` query filters to a single organization.",
        "example": {
          "success": true,
          "response": [
            {
              "organizationId": "44266dea-aea5-421e-88ba-732bb774a0ea",
              "tenantId": "44266dea-aea5-421e-88ba-732bb774a0ea",
              "ecosystemId": "e245e890-5811-457e-aae2-f4d4cf5ade71",
              "dids": [
                {
                  "did": "did:iden3:polygon:amoy:x9GJM81ZjQTtc56k7voGE9q788bYH8nGhxBFYJQoC",
                  "method": "iden3"
                }
              ],
              "name": "Polygon Org",
              "label": "polygonorg",
              "image": "https://hovidevelopment.blob.core.windows.net/studio-assets/tenants/images/polygon-org-image-1778470746748.svg%2Bxml",
              "status": "active",
              "createdAt": "2026-05-11T03:39:10.931Z",
              "updatedAt": "2026-05-11T03:42:37.181Z"
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates whether the organization listing was successfully retrieved. Returns `true` even when no organizations exist (empty array). A `false` value signals a request or server-level failure."
          },
          "response": {
            "type": "array",
            "description": "Array of all organization records registered within this Hovi ecosystem, including archived ones, ordered by creation time descending. Returns an empty array if no organizations have been created yet.",
            "items": {
              "type": "object",
              "properties": {
                "organizationId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Hovi-assigned UUID uniquely identifying this organization. Shares the same value as `tenantId` — both fields refer to the same entity and can be used interchangeably when referencing this organization across Hovi APIs."
                },
                "tenantId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Hovi-assigned UUID for this organization's tenant record. Shares the same value as `organizationId`. Use this as the `x-organization-id` header value in subsequent API requests targeting this organization."
                },
                "ecosystemId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the Hovi ecosystem this organization belongs to. The ecosystem is the top-level platform partition that groups all organizations, schemas, and resources."
                },
                "dids": {
                  "type": "array",
                  "description": "List of DIDs provisioned for this organization. Each entry represents a cryptographic identity used for credential signing and DIDComm communication. Note: unlike the Create Tenant response, this listing endpoint does not return sensitive key material (`privateKey`) for security reasons.",
                  "items": {
                    "type": "object",
                    "properties": {
                      "did": {
                        "type": "string",
                        "description": "The fully-qualified DID string for this organization (e.g., `did:iden3:polygon:amoy:<identifier>`). Used as the issuer identifier when signing credentials."
                      },
                      "method": {
                        "type": "string",
                        "enum": [
                          "iden3"
                        ],
                        "description": "The DID method used for this organization's identifier. `iden3` indicates this DID is anchored on the Polygon Amoy network using the Iden3 protocol."
                      }
                    }
                  }
                },
                "name": {
                  "type": "string",
                  "description": "The full display name of the organization as it appears in Hovi Studio and in credential metadata shown in the holder's wallet (e.g., `\"Polygon Org\"`)."
                },
                "label": {
                  "type": "string",
                  "description": "A URL-safe slug derived from the organization name, used as the default label for DIDComm connection invitations and internal agent routing (e.g., `\"polygonorg\"`)."
                },
                "image": {
                  "type": "string",
                  "format": "url",
                  "description": "URL of the organization's logo image displayed in Hovi Studio and in the holder's wallet during connection and credential acceptance flows. May point to a tenant-specific asset hosted in blob storage (e.g., an `.svg+xml` asset in Azure Blob Storage)."
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "active",
                    "archived"
                  ],
                  "description": "Organization lifecycle status. `active` organizations are fully operational. `archived` organizations remain visible in listings but most mutating operations are blocked."
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of when this organization was first created in the Hovi platform."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent update to this organization record (e.g., name change, image update, or webhook modification)."
                }
              }
            }
          }
        }
      },
      "GetTenantDidsResponse": {
        "title": "Get Tenant DIDs Response",
        "type": "object",
        "description": "Returned when listing all DIDs provisioned for a specific organization on the Polygon Amoy network.",
        "example": {
          "success": true,
          "response": [
            {
              "did": "did:iden3:polygon:amoy:2qSMDANYnqEdDF3s5HpmspaH5ep2rDKR1xE89gWNDn",
              "method": "iden3"
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "array",
            "description": "Array of DIDs provisioned for the organization.",
            "items": {
              "type": "object",
              "properties": {
                "did": {
                  "type": "string",
                  "description": "Full `did:iden3:polygon:amoy` DID string."
                },
                "method": {
                  "type": "string",
                  "enum": [
                    "iden3"
                  ],
                  "description": "DID method — `iden3` for Polygon Amoy."
                }
              }
            }
          }
        }
      },
      "CreateConnectionResponse": {
        "title": "Create Connection Response",
        "type": "object",
        "description": "Returned after successfully generating an Iden3comm connection invitation. The `invitationUri` (`iden3comm://`) is encoded into a QR code or deep link for a Polygon ID-compatible holder wallet to scan and establish a peer channel.",
        "example": {
          "success": true,
          "response": {
            "invitationId": "e53e1006-5ba3-4656-b1b0-d154d2ec6f5d",
            "multiParty": true,
            "createdRequest": {
              "id": "e53e1006-5ba3-4656-b1b0-d154d2ec6f5d",
              "thid": "e53e1006-5ba3-4656-b1b0-d154d2ec6f5d",
              "typ": "application/iden3comm-plain-json",
              "type": "https://iden3-communication.io/authorization/1.0/request",
              "from": "did:iden3:polygon:amoy:2qQSaniB8hK6VRqwJVy5ch56JfYNAGFXKzKj81nQkk",
              "body": {
                "callbackUrl": "https://polygon-agent.hovi.id/connection/did-exchange/e53e1006-5ba3-4656-b1b0-d154d2ec6f5d",
                "scope": []
              }
            },
            "invitationUri": "iden3comm://?i_m=eyJpZCI6ImU1M2UxMDA2LTViYTMtNDY1Ni1iMWIwLWQxNTRkMmVjNmY1ZCIsInRoaWQiOiJlNTNlMTAwNi01YmEzLTQ2NTYtYjFiMC1kMTU0ZDJlYzZmNWQiLCJ0eXAiOiJhcHBsaWNhdGlvbi9pZGVuM2NvbW0tcGxhaW4tanNvbiIsInR5cGUiOiJodHRwczovL2lkZW4zLWNvbW11bmljYXRpb24uaW8vYXV0aG9yaXphdGlvbi8xLjAvcmVxdWVzdCJ9",
            "invitationUrl": "https://hovi.id/connection?data=eyJ1cmkiOiJpZGVuM2NvbW06Ly8...fQ=="
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates whether the connection invitation was successfully generated."
          },
          "response": {
            "type": "object",
            "properties": {
              "invitationId": {
                "type": "string",
                "format": "uuid",
                "description": "Hovi-assigned UUID for this invitation. Use to poll connection state or retrieve the Base64 invitation payload."
              },
              "multiParty": {
                "type": "boolean",
                "description": "`true` — reusable invitation; multiple wallets may connect via the same QR. `false` — single-use, expires after the first wallet completes the handshake."
              },
              "createdRequest": {
                "type": "object",
                "description": "The Iden3comm authorization request message embedded in this invitation.",
                "properties": {
                  "id": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Unique message ID of the Iden3comm request."
                  },
                  "thid": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Thread ID for correlating all messages in this connection exchange."
                  },
                  "typ": {
                    "type": "string",
                    "enum": [
                      "application/iden3comm-plain-json"
                    ],
                    "description": "Iden3comm message content type."
                  },
                  "type": {
                    "type": "string",
                    "enum": [
                      "https://iden3-communication.io/authorization/1.0/request"
                    ],
                    "description": "Iden3comm protocol message type URI."
                  },
                  "from": {
                    "type": "string",
                    "description": "Issuer DID sending this invitation (e.g., `did:iden3:polygon:amoy:...`)."
                  },
                  "body": {
                    "type": "object",
                    "description": "Iden3comm message body.",
                    "properties": {
                      "callbackUrl": {
                        "type": "string",
                        "format": "url",
                        "description": "Polygon agent callback URL where the holder wallet POSTs its DID Exchange response."
                      },
                      "scope": {
                        "type": "array",
                        "description": "Proof scopes attached to this connection request. Empty for pure connection invitations.",
                        "items": {
                          "type": "object"
                        }
                      }
                    }
                  }
                }
              },
              "invitationUri": {
                "type": "string",
                "description": "Iden3comm deep-link URI (`iden3comm://?i_m=...`) containing the Base64-encoded invitation message. Render as a QR code for wallet scanning."
              },
              "invitationUrl": {
                "type": "string",
                "format": "url",
                "description": "Hovi universal app link encapsulating the `invitationUri` for mobile wallet deep linking."
              }
            }
          }
        }
      },
      "GetConnectionsResponse": {
        "title": "Get Connections Response",
        "type": "object",
        "description": "Returned when listing all Iden3comm connection records for an organization. Each item represents a completed or pending peer channel between the organizational agent and a holder wallet.",
        "example": {
          "success": true,
          "response": [
            {
              "connectionId": "89c02ee6-c60f-4e2c-b762-45810a566376",
              "invitationId": "e53e1006-5ba3-4656-b1b0-d154d2ec6f5d",
              "response": {
                "id": "a45c227e-90c3-4054-ab03-d5bff2b89b65",
                "typ": "application/iden3-zkp-json",
                "type": "https://iden3-communication.io/authorization/1.0/response",
                "thid": "e53e1006-5ba3-4656-b1b0-d154d2ec6f5d",
                "body": {
                  "did_doc": {
                    "context": [
                      "https://www.w3.org/ns/did/v1"
                    ],
                    "id": "did:iden3:polygon:amoy:2qWFZnE6b4NQRmWpeVAaHwMGYv2ccYNoLDakLX1LiT",
                    "service": [
                      {
                        "id": "did:iden3:polygon:amoy:2qWFZnE6b4NQRmWpeVAaHwMGYv2ccYNoLDakLX1LiT#mobile",
                        "type": "Iden3MobileServiceV1",
                        "serviceEndpoint": "iden3comm:v0.1:callbackHandler"
                      },
                      {
                        "id": "did:iden3:polygon:amoy:2qWFZnE6b4NQRmWpeVAaHwMGYv2ccYNoLDakLX1LiT#push",
                        "type": "push-notification",
                        "serviceEndpoint": "https://push-staging.polygonid.com/api/v1",
                        "metadata": {
                          "devices": [
                            {
                              "ciphertext": "EGYmomYE...(truncated)",
                              "alg": "RSA-OAEP-512"
                            }
                          ]
                        }
                      }
                    ]
                  },
                  "message": null,
                  "scope": []
                },
                "from": "did:iden3:polygon:amoy:2qWFZnE6b4NQRmWpeVAaHwMGYv2ccYNoLDakLX1LiT",
                "to": "did:iden3:polygon:amoy:2qQSaniB8hK6VRqwJVy5ch56JfYNAGFXKzKj81nQkk"
              },
              "isVerified": true,
              "state": "completed",
              "createdAt": "2024-08-05T10:27:51.189Z",
              "updatedAt": "2024-08-05T10:27:51.189Z",
              "myDid": "did:iden3:polygon:amoy:2qQSaniB8hK6VRqwJVy5ch56JfYNAGFXKzKj81nQkk",
              "theirDid": "did:iden3:polygon:amoy:2qWFZnE6b4NQRmWpeVAaHwMGYv2ccYNoLDakLX1LiT"
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "array",
            "description": "All Iden3comm connection records for the organization.",
            "items": {
              "type": "object",
              "properties": {
                "connectionId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Hovi-assigned UUID for this connection record."
                },
                "invitationId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the invitation that initiated this connection."
                },
                "response": {
                  "type": "object",
                  "description": "The Iden3comm authorization response message submitted by the holder's wallet.",
                  "properties": {
                    "id": {
                      "type": "string",
                      "format": "uuid",
                      "description": "Unique message ID of the holder response."
                    },
                    "typ": {
                      "type": "string",
                      "description": "Iden3comm content type of the response message."
                    },
                    "type": {
                      "type": "string",
                      "description": "Iden3comm protocol message type URI."
                    },
                    "thid": {
                      "type": "string",
                      "format": "uuid",
                      "description": "Thread ID correlating this response to the originating invitation."
                    },
                    "body": {
                      "type": "object",
                      "description": "Iden3comm message body containing the DID document and optional proof scope.",
                      "properties": {
                        "did_doc": {
                          "type": "object",
                          "description": "Holder's DID document submitted during the connection handshake.",
                          "properties": {
                            "context": {
                              "type": "array",
                              "items": {
                                "type": "string"
                              },
                              "description": "JSON-LD contexts for the DID document."
                            },
                            "id": {
                              "type": "string",
                              "description": "Holder's `did:iden3:polygon:amoy` DID."
                            },
                            "service": {
                              "type": "array",
                              "description": "Service endpoints registered in the holder's DID document.",
                              "items": {
                                "type": "object",
                                "properties": {
                                  "id": {
                                    "type": "string",
                                    "description": "Service endpoint identifier."
                                  },
                                  "type": {
                                    "type": "string",
                                    "description": "Service type (e.g., `Iden3MobileServiceV1`, `push-notification`)."
                                  },
                                  "serviceEndpoint": {
                                    "type": "string",
                                    "description": "URL or URI of the service endpoint."
                                  },
                                  "metadata": {
                                    "type": "object",
                                    "description": "Optional metadata for the service (e.g., push notification device ciphertext)."
                                  }
                                }
                              }
                            }
                          }
                        },
                        "message": {
                          "type": "string",
                          "nullable": true,
                          "description": "Optional message attached to the connection response."
                        },
                        "scope": {
                          "type": "array",
                          "description": "Proof scopes included in this response. Empty for pure connection responses.",
                          "items": {
                            "type": "object"
                          }
                        }
                      }
                    },
                    "from": {
                      "type": "string",
                      "description": "Holder's `did:iden3:polygon:amoy` DID."
                    },
                    "to": {
                      "type": "string",
                      "description": "Issuer's `did:iden3:polygon:amoy` DID."
                    }
                  }
                },
                "isVerified": {
                  "type": "boolean",
                  "description": "Whether the Iden3comm authorization response passed cryptographic verification."
                },
                "state": {
                  "type": "string",
                  "enum": [
                    "pending",
                    "completed",
                    "abandoned"
                  ],
                  "description": "Connection lifecycle state."
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp when this connection record was created."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent state change."
                },
                "myDid": {
                  "type": "string",
                  "description": "This organization's `did:iden3:polygon:amoy` DID for this connection."
                },
                "theirDid": {
                  "type": "string",
                  "description": "Holder's `did:iden3:polygon:amoy` DID."
                }
              }
            }
          }
        }
      },
      "GetConnectionResponse": {
        "title": "Get Connection Response",
        "type": "object",
        "description": "Returned when retrieving a specific connection record by `connectionId`.",
        "example": {
          "success": true,
          "response": [
            {
              "connectionId": "5f3d9cc9-6ce1-434e-af8e-c7df69a46bcb",
              "myDid": "did:iden3:polygon:amoy:2qQSaniB8hK6VRqwJVy5ch56JfYNAGFXKzKj81nQkk",
              "createdAt": "2024-08-07T08:35:16.911Z",
              "updatedAt": "2024-08-07T08:35:32.939Z",
              "theirDid": "did:iden3:polygon:amoy:2qWFZnE6b4NQRmWpeVAaHwMGYv2ccYNoLDakLX1LiT",
              "state": "completed",
              "invitationId": "ab209278-db43-45dc-b74e-56a0d83c6f50"
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "array",
            "description": "Matched connection record(s), or empty array if not found.",
            "items": {
              "type": "object",
              "properties": {
                "connectionId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Hovi-assigned UUID for this connection."
                },
                "myDid": {
                  "type": "string",
                  "description": "This organization's `did:iden3:polygon:amoy` DID."
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp when this connection was created."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent state change."
                },
                "theirDid": {
                  "type": "string",
                  "description": "Holder's `did:iden3:polygon:amoy` DID."
                },
                "state": {
                  "type": "string",
                  "enum": [
                    "pending",
                    "completed",
                    "abandoned"
                  ],
                  "description": "Connection lifecycle state."
                },
                "invitationId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the invitation that initiated this connection."
                }
              }
            }
          }
        }
      },
      "GetConnectionsForInvitationResponse": {
        "title": "Get Connections For Invitation Response",
        "type": "object",
        "description": "Returned when listing all connection records associated with a specific invitation ID. Useful for multi-party invitations where multiple wallets may have connected via the same QR code.",
        "example": {
          "success": true,
          "response": [
            {
              "connectionId": "89c02ee6-c60f-4e2c-b762-45810a566376",
              "invitationId": "e53e1006-5ba3-4656-b1b0-d154d2ec6f5d",
              "isVerified": true,
              "state": "completed",
              "createdAt": "2024-08-05T10:27:51.189Z",
              "updatedAt": "2024-08-05T10:27:51.189Z",
              "myDid": "did:iden3:polygon:amoy:2qQSaniB8hK6VRqwJVy5ch56JfYNAGFXKzKj81nQkk",
              "theirDid": "did:iden3:polygon:amoy:2qWFZnE6b4NQRmWpeVAaHwMGYv2ccYNoLDakLX1LiT"
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "array",
            "description": "All connection records for the specified invitation.",
            "items": {
              "type": "object",
              "properties": {
                "connectionId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Hovi-assigned UUID for this connection."
                },
                "invitationId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the invitation that initiated this connection."
                },
                "isVerified": {
                  "type": "boolean",
                  "description": "Whether the Iden3comm handshake passed cryptographic verification."
                },
                "state": {
                  "type": "string",
                  "enum": [
                    "pending",
                    "completed",
                    "abandoned"
                  ],
                  "description": "Connection lifecycle state."
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp when this connection was created."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent state change."
                },
                "myDid": {
                  "type": "string",
                  "description": "This organization's `did:iden3:polygon:amoy` DID."
                },
                "theirDid": {
                  "type": "string",
                  "description": "Holder's `did:iden3:polygon:amoy` DID."
                }
              }
            }
          }
        }
      },
      "GetConnectionInvitationsResponse": {
        "title": "Get Connection Invitations Response",
        "type": "object",
        "description": "Returned when listing all Iden3comm connection invitations created by the organization.",
        "example": {
          "success": true,
          "response": [
            {
              "createdAt": "2024-08-05T10:18:14.374Z",
              "updatedAt": "2024-08-05T10:27:51.442Z",
              "invitationId": "e53e1006-5ba3-4656-b1b0-d154d2ec6f5d",
              "multiParty": true,
              "numberOfResponses": 1,
              "state": "pending"
            },
            {
              "createdAt": "2024-08-06T05:53:25.274Z",
              "updatedAt": "2024-08-06T05:54:25.177Z",
              "invitationId": "x69z004-5ba3-4656-b1b0-d154d2ec6e2d",
              "multiParty": true,
              "numberOfResponses": 2,
              "state": "pending"
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "array",
            "description": "All connection invitations created by this organization.",
            "items": {
              "type": "object",
              "properties": {
                "invitationId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Unique identifier for this invitation."
                },
                "multiParty": {
                  "type": "boolean",
                  "description": "`true` — reusable invitation. `false` — single-use."
                },
                "numberOfResponses": {
                  "type": "number",
                  "description": "Number of wallets that have responded to this invitation."
                },
                "state": {
                  "type": "string",
                  "enum": [
                    "pending",
                    "completed",
                    "abandoned"
                  ],
                  "description": "Current invitation lifecycle state."
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp when this invitation was created."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent update."
                }
              }
            }
          }
        }
      },
      "GetConnectionInvitationResponse": {
        "title": "Get Connection Invitation Response",
        "type": "object",
        "description": "Returned when retrieving a specific Iden3comm connection invitation by its ID. Includes the full invitation URI and the original Iden3comm request message.",
        "example": {
          "success": true,
          "response": {
            "invitationId": "18e3739d-7f6e-4865-a0b8-092e72119f6c",
            "createdAt": "2024-07-29T11:06:35.166Z",
            "updatedAt": "2024-07-29T11:12:34.642Z",
            "invitationUri": "iden3comm://?i_m=eyJpZCI6IjE4ZTM3MzlkLTdmNmUtNDg2NS1hMGI4LTA5MmU3MjExOWY2YyIsInRoaWQiOiIxOGUzNzM5ZC03ZjZlLTQ4NjUtYTBiOC0wOTJlNzIxMTlmNmMi...(truncated)",
            "invitationUrl": "https://hovi.id/connection?data=eyJ1cmkiOiJpZGVuM2NvbW06Ly8...(truncated)",
            "multiParty": true,
            "numberOfResponses": 1,
            "state": "pending",
            "requestType": "did_exchange",
            "request": {
              "id": "18e3739d-7f6e-4865-a0b8-092e72119f6c",
              "thid": "18e3739d-7f6e-4865-a0b8-092e72119f6c",
              "typ": "application/iden3comm-plain-json",
              "type": "https://iden3-communication.io/authorization/1.0/request",
              "from": "did:iden3:polygon:amoy:2qUNf93PcLdfieMRDaiuGEzwfZvWZL6EbGWvSbiFUF",
              "body": {
                "callbackUrl": "https://polygon-agent.hovi.id/connection/did-exchange/18e3739d-7f6e-4865-a0b8-092e72119f6c",
                "scope": []
              }
            }
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "object",
            "properties": {
              "invitationId": {
                "type": "string",
                "format": "uuid",
                "description": "Unique identifier for this invitation."
              },
              "createdAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp when this invitation was created."
              },
              "updatedAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp of the most recent update."
              },
              "invitationUri": {
                "type": "string",
                "description": "Iden3comm deep-link URI (`iden3comm://?i_m=...`) for wallet scanning."
              },
              "invitationUrl": {
                "type": "string",
                "format": "url",
                "description": "Hovi universal app link encapsulating the `invitationUri`."
              },
              "multiParty": {
                "type": "boolean",
                "description": "`true` — reusable invitation. `false` — single-use."
              },
              "numberOfResponses": {
                "type": "number",
                "description": "Number of wallets that have responded to this invitation."
              },
              "state": {
                "type": "string",
                "enum": [
                  "pending",
                  "completed",
                  "abandoned"
                ],
                "description": "Current invitation lifecycle state."
              },
              "requestType": {
                "type": "string",
                "enum": [
                  "did_exchange",
                  "presentation_exchange_request",
                  "credential_exchange_request"
                ],
                "description": "Type of Iden3comm exchange this invitation initiates."
              },
              "request": {
                "type": "object",
                "description": "The full Iden3comm authorization request message embedded in this invitation.",
                "properties": {
                  "id": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Unique message ID."
                  },
                  "thid": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Thread ID for this exchange."
                  },
                  "typ": {
                    "type": "string",
                    "description": "Iden3comm content type."
                  },
                  "type": {
                    "type": "string",
                    "description": "Iden3comm protocol message type URI."
                  },
                  "from": {
                    "type": "string",
                    "description": "Issuer's `did:iden3:polygon:amoy` DID."
                  },
                  "body": {
                    "type": "object",
                    "properties": {
                      "callbackUrl": {
                        "type": "string",
                        "format": "url",
                        "description": "Polygon agent callback URL for the holder response."
                      },
                      "scope": {
                        "type": "array",
                        "description": "Proof scopes. Empty for DID exchange invitations.",
                        "items": {
                          "type": "object"
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "SendProofRequestResponse": {
        "title": "Send Proof Request Response",
        "type": "object",
        "description": "Returned after successfully initiating a Polygon proof request. The `proofRequestUri` (`iden3comm://`) and `verificationUrl` are encoded into a QR code or deep link for the holder wallet to scan and submit a ZK proof.",
        "example": {
          "success": true,
          "response": {
            "proofExchangeId": "ac63dbf7-29dd-44e3-bf0d-3788b09e12b5",
            "verificationUrl": "https://hovi.id/verification?data=eyJ1cmkiOiJpZGVuM2NvbW06Ly8...(truncated)",
            "proofRequestUri": "iden3comm://?i_m=eyJpZCI6ImFjNjNkYmY3...(truncated)",
            "createdRequest": {
              "id": "ac63dbf7-29dd-44e3-bf0d-3788b09e12b5",
              "thid": "ac63dbf7-29dd-44e3-bf0d-3788b09e12b5",
              "typ": "application/iden3comm-plain-json",
              "type": "https://iden3-communication.io/authorization/1.0/request",
              "from": "did:iden3:polygon:amoy:2qQSaniB8hK6VRqwJVy5ch56JfYNAGFXKzKj81nQkk",
              "body": {
                "callbackUrl": "https://polygon-agent-dev.hovi.id/proof/verify-presentation/ac63dbf7-29dd-44e3-bf0d-3788b09e12b5",
                "scope": [
                  {
                    "circuitId": "credentialAtomicQuerySigV2",
                    "id": 1,
                    "query": {
                      "allowedIssuers": [
                        "*"
                      ],
                      "type": "University Degree Record 7",
                      "credentialSubject": {
                        "university.batch.passingYear": {
                          "$in": [
                            2000,
                            2021,
                            2022
                          ]
                        }
                      }
                    }
                  },
                  {
                    "circuitId": "credentialAtomicQuerySigV2",
                    "id": 2,
                    "query": {
                      "allowedIssuers": [
                        "*"
                      ],
                      "type": "University Degree Record 7",
                      "credentialSubject": {
                        "fullName": {
                          "$eq": "John Doe"
                        }
                      }
                    }
                  }
                ]
              }
            }
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the proof request was successfully initiated."
          },
          "response": {
            "type": "object",
            "properties": {
              "proofExchangeId": {
                "type": "string",
                "format": "uuid",
                "description": "Hovi-assigned UUID for this proof exchange session. Use to poll for state and retrieve ZK proof responses."
              },
              "verificationUrl": {
                "type": "string",
                "format": "url",
                "description": "Hovi universal app link encapsulating the proof request for mobile wallet deep linking."
              },
              "proofRequestUri": {
                "type": "string",
                "description": "Iden3comm deep-link URI (`iden3comm://?i_m=...`) for wallet scanning. Encode as QR code for holder presentation."
              },
              "createdRequest": {
                "type": "object",
                "description": "The full Iden3comm authorization request message for this proof exchange.",
                "properties": {
                  "id": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Unique message ID of the proof request."
                  },
                  "thid": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Thread ID correlating all messages in this proof exchange."
                  },
                  "typ": {
                    "type": "string",
                    "enum": [
                      "application/iden3comm-plain-json"
                    ],
                    "description": "Iden3comm content type."
                  },
                  "type": {
                    "type": "string",
                    "enum": [
                      "https://iden3-communication.io/authorization/1.0/request"
                    ],
                    "description": "Iden3comm protocol message type URI."
                  },
                  "from": {
                    "type": "string",
                    "description": "Verifier's `did:iden3:polygon:amoy` DID."
                  },
                  "body": {
                    "type": "object",
                    "properties": {
                      "callbackUrl": {
                        "type": "string",
                        "format": "url",
                        "description": "Polygon agent callback URL where the holder wallet POSTs its ZK proof response."
                      },
                      "scope": {
                        "type": "array",
                        "description": "Iden3 proof scope definitions — each maps to one `credentialAtomicQuerySigV2` circuit query.",
                        "items": {
                          "type": "object",
                          "properties": {
                            "circuitId": {
                              "type": "string",
                              "enum": [
                                "credentialAtomicQuerySigV2"
                              ],
                              "description": "Iden3 ZK circuit for this scope."
                            },
                            "id": {
                              "type": "number",
                              "description": "Numeric scope identifier."
                            },
                            "query": {
                              "type": "object",
                              "properties": {
                                "allowedIssuers": {
                                  "type": "array",
                                  "items": {
                                    "type": "string"
                                  },
                                  "description": "Accepted issuer DIDs."
                                },
                                "type": {
                                  "type": "string",
                                  "description": "JSON-LD `@type` of the target credential."
                                },
                                "credentialSubject": {
                                  "type": "object",
                                  "description": "Query conditions on credential subject fields."
                                }
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "GetProofRequestsResponse": {
        "title": "Get Proof Requests Response",
        "type": "object",
        "description": "Returned when listing all proof exchange records for the organization.",
        "example": {
          "success": true,
          "response": [
            {
              "proofExchangeId": "acd42bba-891b-4577-9218-a51ce3f67e37",
              "state": "done",
              "isVerified": true,
              "createdAt": "2024-08-02T11:35:13.926Z",
              "updatedAt": "2024-08-02T11:38:54.481Z",
              "numberOfResponses": 1
            },
            {
              "proofExchangeId": "5896d0ce-8b0b-4de4-a76e-ab01c0bb72f8",
              "state": "pending",
              "isVerified": false,
              "createdAt": "2024-08-02T11:42:54.065Z",
              "updatedAt": "2024-08-02T11:42:54.065Z",
              "numberOfResponses": 0
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "array",
            "description": "All proof exchange records for the organization.",
            "items": {
              "type": "object",
              "properties": {
                "proofExchangeId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Unique identifier for this proof exchange session."
                },
                "state": {
                  "type": "string",
                  "enum": [
                    "pending",
                    "done",
                    "abandoned"
                  ],
                  "description": "Proof exchange state. `done` — ZK proof received and verified."
                },
                "isVerified": {
                  "type": "boolean",
                  "description": "Whether the submitted ZK proof passed cryptographic verification."
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp when this proof exchange was initiated."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent state change."
                },
                "numberOfResponses": {
                  "type": "number",
                  "description": "Number of ZK proof responses received for this exchange."
                }
              }
            }
          }
        }
      },
      "GetProofRequestResponse": {
        "title": "Get Proof Request Response",
        "type": "object",
        "description": "Returned when retrieving a single proof exchange by ID. When `state` is `done`, includes the full Iden3comm request message, `requestType`, `verificationUrl`, and `proofRequestUri`.",
        "example": {
          "success": true,
          "response": {
            "proofExchangeId": "acd42bba-891b-4577-9218-a51ce3f67e37",
            "state": "done",
            "isVerified": true,
            "createdAt": "2024-08-02T11:35:13.926Z",
            "updatedAt": "2024-08-02T11:38:54.481Z",
            "isMultiParty": false,
            "numberOfResponses": 1,
            "requestType": "presentation_exchange_request",
            "verificationUrl": "https://hovi.id/verification?data=eyJ1cmkiOiJpZGVuM2NvbW06Ly8...(truncated)",
            "proofRequestUri": "iden3comm://?i_m=eyJpZCI6ImFjZDQyYmJhLTg5MWItNDU3Ny05MjE4...(truncated)",
            "request": {
              "id": "acd42bba-891b-4577-9218-a51ce3f67e37",
              "thid": "acd42bba-891b-4577-9218-a51ce3f67e37",
              "typ": "application/iden3comm-plain-json",
              "type": "https://iden3-communication.io/authorization/1.0/request",
              "from": "did:iden3:polygon:amoy:2qUNf93PcLdfieMRDaiuGEzwfZvWZL6EbGWvSbiFUF",
              "body": {
                "callbackUrl": "https://polygon-agent-dev.hovi.id/proof/verify-presentation/acd42bba-891b-4577-9218-a51ce3f67e37",
                "scope": [
                  {
                    "circuitId": "credentialAtomicQuerySigV2",
                    "id": 1722589673,
                    "query": {
                      "allowedIssuers": [
                        "*"
                      ],
                      "context": "https://hovi.id/schemas/QmPxUiou4B8A5ee8udcfY1GUxU4CehTi8ZtuSh1wivhqmx",
                      "type": "University Degree Record 7",
                      "credentialSubject": {
                        "university.batch.passingYear": {
                          "$gt": 2000
                        }
                      }
                    }
                  }
                ]
              }
            }
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "object",
            "properties": {
              "proofExchangeId": {
                "type": "string",
                "format": "uuid",
                "description": "Unique identifier for this proof exchange session."
              },
              "state": {
                "type": "string",
                "enum": [
                  "pending",
                  "done",
                  "abandoned"
                ],
                "description": "Current proof exchange state."
              },
              "isVerified": {
                "type": "boolean",
                "description": "Whether the ZK proof response passed cryptographic verification."
              },
              "createdAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp when this proof exchange was initiated."
              },
              "updatedAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp of the most recent state change."
              },
              "isMultiParty": {
                "type": "boolean",
                "description": "Whether this proof request accepts responses from multiple holder wallets."
              },
              "numberOfResponses": {
                "type": "number",
                "description": "Number of ZK proof responses received."
              },
              "requestType": {
                "type": "string",
                "enum": [
                  "presentation_exchange_request",
                  "credential_exchange_request",
                  "did_exchange"
                ],
                "description": "Type of Iden3comm exchange this proof request initiated."
              },
              "verificationUrl": {
                "type": "string",
                "format": "url",
                "description": "Hovi universal app link for mobile wallet deep linking."
              },
              "proofRequestUri": {
                "type": "string",
                "description": "Iden3comm deep-link URI for wallet QR scanning."
              },
              "request": {
                "type": "object",
                "description": "The full Iden3comm authorization request message for this proof exchange.",
                "properties": {
                  "id": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Unique message ID."
                  },
                  "thid": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Thread ID."
                  },
                  "typ": {
                    "type": "string",
                    "description": "Iden3comm content type."
                  },
                  "type": {
                    "type": "string",
                    "description": "Iden3comm protocol message type URI."
                  },
                  "from": {
                    "type": "string",
                    "description": "Verifier's `did:iden3:polygon:amoy` DID."
                  },
                  "body": {
                    "type": "object",
                    "properties": {
                      "callbackUrl": {
                        "type": "string",
                        "format": "url",
                        "description": "Polygon agent callback URL for holder ZK proof responses."
                      },
                      "scope": {
                        "type": "array",
                        "description": "Proof scope definitions for this request.",
                        "items": {
                          "type": "object",
                          "properties": {
                            "circuitId": {
                              "type": "string",
                              "enum": [
                                "credentialAtomicQuerySigV2"
                              ],
                              "description": "Iden3 ZK circuit."
                            },
                            "id": {
                              "type": "number",
                              "description": "Numeric scope identifier."
                            },
                            "query": {
                              "type": "object",
                              "properties": {
                                "allowedIssuers": {
                                  "type": "array",
                                  "items": {
                                    "type": "string"
                                  },
                                  "description": "Accepted issuers."
                                },
                                "context": {
                                  "type": "string",
                                  "format": "url",
                                  "description": "JSON-LD `@context` URL for the credential schema."
                                },
                                "type": {
                                  "type": "string",
                                  "description": "JSON-LD `@type` of the target credential."
                                },
                                "credentialSubject": {
                                  "type": "object",
                                  "description": "Query conditions on credential subject fields."
                                }
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "GetProofResponsesResponse": {
        "title": "Get Proof Responses Response",
        "type": "object",
        "description": "Returned when listing all ZK proof responses for a proof exchange. Each item contains the holder's full Iden3comm authorization response and the associated ZK proof data.",
        "example": {
          "success": true,
          "response": [
            {
              "createdAt": "2024-08-06T11:29:03.807Z",
              "updatedAt": "2024-08-06T11:29:03.807Z",
              "proofExchangeId": "b030a308-8ede-4339-be4c-7c91651056fd",
              "isVerified": true,
              "presentationId": "0f6bf2a7-4f99-4253-bd44-5299cf904ac5",
              "response": {
                "id": "140f5673-8c4d-49df-ad98-693ad0278554",
                "typ": "application/iden3-zkp-json",
                "type": "https://iden3-communication.io/authorization/1.0/response",
                "thid": "b030a308-8ede-4339-be4c-7c91651056fd",
                "from": "did:iden3:polygon:amoy:2qUts7TyXR7TPD4EfEtvh9EvCuR8NEjokpkWzGMRdN",
                "to": "did:iden3:polygon:amoy:2qUNf93PcLdfieMRDaiuGEzwfZvWZL6EbGWvSbiFUF",
                "body": {
                  "did_doc": {
                    "context": [
                      "https://www.w3.org/ns/did/v1"
                    ],
                    "id": "did:iden3:polygon:amoy:2qUts7TyXR7TPD4EfEtvh9EvCuR8NEjokpkWzGMRdN",
                    "service": [
                      {
                        "id": "did:iden3:polygon:amoy:2qUts7TyXR7TPD4EfEtvh9EvCuR8NEjokpkWzGMRdN#mobile",
                        "type": "Iden3MobileServiceV1",
                        "serviceEndpoint": "iden3comm:v0.1:callbackHandler"
                      },
                      {
                        "id": "did:iden3:polygon:amoy:2qUts7TyXR7TPD4EfEtvh9EvCuR8NEjokpkWzGMRdN#push",
                        "type": "push-notification",
                        "serviceEndpoint": "https://push-staging.polygonid.com/api/v1",
                        "metadata": {
                          "devices": [
                            {
                              "ciphertext": "0dy1wf8F5b...(truncated)",
                              "alg": "RSA-OAEP-512"
                            }
                          ]
                        }
                      }
                    ]
                  },
                  "message": null,
                  "scope": []
                }
              }
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "array",
            "description": "All ZK proof response records for this proof exchange.",
            "items": {
              "type": "object",
              "properties": {
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp when this proof response was received."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent update."
                },
                "proofExchangeId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the proof exchange this response belongs to."
                },
                "isVerified": {
                  "type": "boolean",
                  "description": "Whether this ZK proof response passed cryptographic verification."
                },
                "presentationId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Unique identifier for this specific proof presentation response."
                },
                "response": {
                  "type": "object",
                  "description": "Full Iden3comm authorization response submitted by the holder's wallet.",
                  "properties": {
                    "id": {
                      "type": "string",
                      "format": "uuid",
                      "description": "Unique message ID of the response."
                    },
                    "typ": {
                      "type": "string",
                      "description": "Iden3comm ZK JSON content type (`application/iden3-zkp-json`)."
                    },
                    "type": {
                      "type": "string",
                      "description": "Iden3comm protocol message type URI."
                    },
                    "thid": {
                      "type": "string",
                      "format": "uuid",
                      "description": "Thread ID correlating this response to the proof request."
                    },
                    "from": {
                      "type": "string",
                      "description": "Holder's `did:iden3:polygon:amoy` DID."
                    },
                    "to": {
                      "type": "string",
                      "description": "Verifier's `did:iden3:polygon:amoy` DID."
                    },
                    "body": {
                      "type": "object",
                      "properties": {
                        "did_doc": {
                          "type": "object",
                          "description": "Holder's DID document submitted with the proof response."
                        },
                        "message": {
                          "type": "string",
                          "nullable": true,
                          "description": "Optional message from the holder."
                        },
                        "scope": {
                          "type": "array",
                          "description": "Array of Groth16 ZK proof objects — one per proof scope in the original request.",
                          "items": {
                            "type": "object",
                            "properties": {
                              "proof": {
                                "type": "object",
                                "description": "Groth16 ZK proof data.",
                                "properties": {
                                  "pi_a": {
                                    "type": "array",
                                    "items": {
                                      "type": "string"
                                    },
                                    "description": "Groth16 proof element A (G1 point)."
                                  },
                                  "pi_b": {
                                    "type": "array",
                                    "items": {
                                      "type": "array",
                                      "items": {
                                        "type": "string"
                                      }
                                    },
                                    "description": "Groth16 proof element B (G2 point)."
                                  },
                                  "pi_c": {
                                    "type": "array",
                                    "items": {
                                      "type": "string"
                                    },
                                    "description": "Groth16 proof element C (G1 point)."
                                  },
                                  "protocol": {
                                    "type": "string",
                                    "enum": [
                                      "groth16"
                                    ],
                                    "description": "ZK proof protocol."
                                  },
                                  "curve": {
                                    "type": "string",
                                    "enum": [
                                      "bn128"
                                    ],
                                    "description": "Elliptic curve used for the proof."
                                  }
                                }
                              },
                              "pub_signals": {
                                "type": "array",
                                "items": {
                                  "type": "string"
                                },
                                "description": "Public signals for the Groth16 proof verifier."
                              },
                              "id": {
                                "type": "number",
                                "description": "Scope ID matching the original proof request scope."
                              },
                              "circuitId": {
                                "type": "string",
                                "enum": [
                                  "credentialAtomicQuerySigV2"
                                ],
                                "description": "Iden3 ZK circuit used to generate this proof."
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "GetProofResponseResponse": {
        "title": "Get Proof Response Response",
        "type": "object",
        "description": "Returned when retrieving a single ZK proof response by `presentationId`. Contains the full Groth16 proof payload including `pi_a`, `pi_b`, `pi_c`, `pub_signals`, and the Iden3comm DID document.",
        "example": {
          "success": true,
          "response": {
            "createdAt": "2024-08-02T11:38:54.237Z",
            "updatedAt": "2024-08-02T11:38:54.237Z",
            "proofExchangeId": "acd42bba-891b-4577-9218-a51ce3f67e37",
            "isVerified": true,
            "presentationId": "d78c9b23-427e-402c-a8d6-25bbee602597",
            "response": {
              "id": "1e163901-00f5-410d-b0ea-f888f857d300",
              "typ": "application/iden3-zkp-json",
              "type": "https://iden3-communication.io/authorization/1.0/response",
              "thid": "acd42bba-891b-4577-9218-a51ce3f67e37",
              "from": "did:iden3:polygon:amoy:2qUts7TyXR7TPD4EfEtvh9EvCuR8NEjokpkWzGMRdN",
              "to": "did:iden3:polygon:amoy:2qUNf93PcLdfieMRDaiuGEzwfZvWZL6EbGWvSbiFUF",
              "body": {
                "did_doc": {
                  "context": [
                    "https://www.w3.org/ns/did/v1"
                  ],
                  "id": "did:iden3:polygon:amoy:2qUts7TyXR7TPD4EfEtvh9EvCuR8NEjokpkWzGMRdN",
                  "service": [
                    {
                      "id": "did:iden3:polygon:amoy:2qUts7TyXR7TPD4EfEtvh9EvCuR8NEjokpkWzGMRdN#mobile",
                      "type": "Iden3MobileServiceV1",
                      "serviceEndpoint": "iden3comm:v0.1:callbackHandler"
                    },
                    {
                      "id": "did:iden3:polygon:amoy:2qUts7TyXR7TPD4EfEtvh9EvCuR8NEjokpkWzGMRdN#push",
                      "type": "push-notification",
                      "serviceEndpoint": "https://push-staging.polygonid.com/api/v1",
                      "metadata": {
                        "devices": [
                          {
                            "ciphertext": "R6hNVQDV...(truncated)",
                            "alg": "RSA-OAEP-512"
                          }
                        ]
                      }
                    }
                  ]
                },
                "message": null,
                "scope": [
                  {
                    "proof": {
                      "pi_a": [
                        "1841402755199166250034242792535067262511410558683553810159510627777942956614",
                        "125744564865622775266902447469709365381043967692055208685288834191128150522",
                        "1"
                      ],
                      "pi_b": [
                        [
                          "9594440926911581241287727225722301982109644997256682324805944553313524634946",
                          "11565295827744962873774617627414137749955160085134551278427430722206524945299"
                        ],
                        [
                          "1479675336008373946106127040434847730831463379463342980782844960716119618140",
                          "11662034923894778106533052358864242035782777137376050474667036755873654802737"
                        ],
                        [
                          "1",
                          "0"
                        ]
                      ],
                      "pi_c": [
                        "14683991008366759908148689108245984383879186891268433456140944765595294225829",
                        "1094953752304781461119386460234892845707396369911231281129554885878524790859",
                        "1"
                      ],
                      "protocol": "groth16",
                      "curve": "bn128"
                    },
                    "pub_signals": [
                      "1",
                      "24082793358012584608174579977337611999996213347949865794732459169602409218",
                      "11308706860893816827371066764962337889424544939857771213011409856915723265787",
                      "1722589673",
                      "0",
                      "0"
                    ],
                    "id": 1722589673,
                    "circuitId": "credentialAtomicQuerySigV2"
                  }
                ]
              }
            }
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "object",
            "properties": {
              "createdAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp when this proof response was received."
              },
              "updatedAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp of the most recent update."
              },
              "proofExchangeId": {
                "type": "string",
                "format": "uuid",
                "description": "UUID of the proof exchange this response belongs to."
              },
              "isVerified": {
                "type": "boolean",
                "description": "Whether this ZK proof passed cryptographic verification."
              },
              "presentationId": {
                "type": "string",
                "format": "uuid",
                "description": "Unique identifier for this presentation response."
              },
              "response": {
                "type": "object",
                "description": "Full Iden3comm authorization response submitted by the holder's wallet.",
                "properties": {
                  "id": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Unique message ID."
                  },
                  "typ": {
                    "type": "string",
                    "description": "Iden3comm ZK JSON content type."
                  },
                  "type": {
                    "type": "string",
                    "description": "Iden3comm protocol message type URI."
                  },
                  "thid": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Thread ID correlating this response to the proof request."
                  },
                  "from": {
                    "type": "string",
                    "description": "Holder's `did:iden3:polygon:amoy` DID."
                  },
                  "to": {
                    "type": "string",
                    "description": "Verifier's `did:iden3:polygon:amoy` DID."
                  },
                  "body": {
                    "type": "object",
                    "properties": {
                      "did_doc": {
                        "type": "object",
                        "description": "Holder's DID document."
                      },
                      "message": {
                        "type": "string",
                        "nullable": true,
                        "description": "Optional message from the holder."
                      },
                      "scope": {
                        "type": "array",
                        "description": "Groth16 ZK proof objects for each scope in the original request.",
                        "items": {
                          "type": "object",
                          "properties": {
                            "proof": {
                              "type": "object",
                              "description": "Groth16 ZK proof.",
                              "properties": {
                                "pi_a": {
                                  "type": "array",
                                  "items": {
                                    "type": "string"
                                  },
                                  "description": "G1 point A."
                                },
                                "pi_b": {
                                  "type": "array",
                                  "items": {
                                    "type": "array",
                                    "items": {
                                      "type": "string"
                                    }
                                  },
                                  "description": "G2 point B."
                                },
                                "pi_c": {
                                  "type": "array",
                                  "items": {
                                    "type": "string"
                                  },
                                  "description": "G1 point C."
                                },
                                "protocol": {
                                  "type": "string",
                                  "enum": [
                                    "groth16"
                                  ],
                                  "description": "ZK proof protocol."
                                },
                                "curve": {
                                  "type": "string",
                                  "enum": [
                                    "bn128"
                                  ],
                                  "description": "Elliptic curve."
                                }
                              }
                            },
                            "pub_signals": {
                              "type": "array",
                              "items": {
                                "type": "string"
                              },
                              "description": "Public signals for proof verification."
                            },
                            "id": {
                              "type": "number",
                              "description": "Scope ID matching the original request."
                            },
                            "circuitId": {
                              "type": "string",
                              "enum": [
                                "credentialAtomicQuerySigV2"
                              ],
                              "description": "Iden3 ZK circuit."
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "GetProofResponseByProofIdResponse": {
        "title": "Get Proof Responses By Proof Exchange ID",
        "type": "object",
        "description": "Returned when listing all ZK proof responses associated with a specific `proofExchangeId`.",
        "example": {
          "success": true,
          "response": [
            {
              "createdAt": "2024-08-02T11:38:54.237Z",
              "updatedAt": "2024-08-02T11:38:54.237Z",
              "proofExchangeId": "acd42bba-891b-4577-9218-a51ce3f67e37",
              "isVerified": true,
              "presentationId": "d78c9b23-427e-402c-a8d6-25bbee602597"
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "array",
            "description": "All ZK proof response records for the specified proof exchange.",
            "items": {
              "type": "object",
              "properties": {
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp when this response was received."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent update."
                },
                "proofExchangeId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "UUID of the proof exchange this response belongs to."
                },
                "isVerified": {
                  "type": "boolean",
                  "description": "Whether this ZK proof passed cryptographic verification."
                },
                "presentationId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Unique identifier for this presentation response."
                }
              }
            }
          }
        }
      },
      "GetAllCredentialsResponse": {
        "title": "Get All Credentials Response",
        "type": "object",
        "description": "Returned when listing all credential exchange records for the organization.",
        "example": {
          "success": true,
          "response": [
            {
              "credentialExchangeId": "cf37f0fd-47a0-4f50-869f-b162c61a7270",
              "credentialType": "jsonld-sig",
              "state": "done",
              "revoked": false,
              "createdAt": "2024-08-05T10:58:05.907Z",
              "updatedAt": "2024-08-05T10:58:52.617Z"
            }
          ]
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "array",
            "description": "All credential exchange records for the organization.",
            "items": {
              "type": "object",
              "properties": {
                "credentialExchangeId": {
                  "type": "string",
                  "format": "uuid",
                  "description": "Hovi-assigned UUID for this credential exchange session."
                },
                "credentialType": {
                  "type": "string",
                  "enum": [
                    "jsonld-sig"
                  ],
                  "description": "Polygon-specific credential proof type. `jsonld-sig` — JSON-LD credential with Iden3 BJJSignature2021 proof."
                },
                "state": {
                  "type": "string",
                  "enum": [
                    "pending",
                    "done",
                    "abandoned"
                  ],
                  "description": "Credential exchange state. `done` — credential successfully issued and claimed by the holder."
                },
                "revoked": {
                  "type": "boolean",
                  "description": "Whether this credential has been revoked via the Iden3 Reverse Sparse Merkle Tree."
                },
                "createdAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp when this credential exchange was created."
                },
                "updatedAt": {
                  "type": "string",
                  "format": "date-time",
                  "description": "ISO 8601 timestamp of the most recent update."
                }
              }
            }
          }
        }
      },
      "GetCredentialResponse": {
        "title": "Get Credential Response",
        "type": "object",
        "description": "Returned when retrieving a specific credential exchange record by ID. When `state` is `done`, includes the full JSON-LD Verifiable Credential with Iden3 BJJSignature2021 proof, `credentialOfferUrl`, and `credentialOfferUri`.",
        "example": {
          "success": true,
          "response": {
            "credentialExchangeId": "cf37f0fd-47a0-4f50-869f-b162c61a7270",
            "credentialType": "jsonld-sig",
            "state": "done",
            "revoked": false,
            "requestType": "credential_exchange_request",
            "createdAt": "2024-08-05T10:58:05.907Z",
            "updatedAt": "2024-08-05T10:58:52.617Z",
            "credentialOfferUrl": "https://hovi.id/credential?data=eyJ1cmkiOiJpZGVuM2NvbW06Ly8...(truncated)",
            "credentialOfferUri": "iden3comm://?i_m=eyJpZCI6ImNmMzdmMGZkLTQ3YTAtNGY1MC04NjlmLWIxNjJjNjFhNzI3MCIsInRoaWQiOiJjZjM3ZjBmZC00N2EwLTRmNTAtODY5Zi1iMTYyYzYxYTcyNzAi...(truncated)",
            "credential": {
              "id": "urn:d5052970-901b-4693-a920-e41b4f1da749",
              "@context": [
                "https://www.w3.org/2018/credentials/v1",
                "https://schema.iden3.io/core/jsonld/iden3proofs.jsonld",
                "https://hovi.id/schemas/QmPxUiou4B8A5ee8udcfY1GUxU4CehTi8ZtuSh1wivhqmx"
              ],
              "type": [
                "VerifiableCredential",
                "University Degree Record"
              ],
              "credentialSubject": {
                "university": {
                  "batch": {
                    "passingYear": 2021
                  },
                  "branch": "KHI"
                },
                "fullName": "John Doe",
                "id": "did:iden3:polygon:amoy:2qWFZnE6b4NQRmWpeVAaHwMGYv2ccYNoLDakLX1LiT",
                "type": "University Degree Record"
              },
              "issuer": "did:iden3:polygon:amoy:2qQSaniB8hK6VRqwJVy5ch56JfYNAGFXKzKj81nQkk",
              "issuanceDate": "2024-08-05T10:57:54.845Z",
              "expirationDate": null,
              "credentialSchema": {
                "id": "https://hovi.id/schemas/QmRF7nnhYTsWu8sqA2jeLWbWP9LuuARS9RrWsL2akvwD7v",
                "type": "JsonSchema2023"
              },
              "credentialStatus": {
                "id": "https://rhs-staging.polygonid.me/node?state=cd83bd788807c4ec304cc17b6b773b6ad4a68ad0ca6244ecaa0bf60f2abe1b19",
                "type": "Iden3ReverseSparseMerkleTreeProof",
                "revocationNonce": 4215561986
              },
              "proof": [
                {
                  "type": "BJJSignature2021",
                  "issuerData": {
                    "id": "did:iden3:polygon:amoy:2qQSaniB8hK6VRqwJVy5ch56JfYNAGFXKzKj81nQkk",
                    "state": {
                      "rootOfRoots": "0000000000000000000000000000000000000000000000000000000000000000",
                      "revocationTreeRoot": "0000000000000000000000000000000000000000000000000000000000000000",
                      "claimsTreeRoot": "bedcfe8dac6fb708f2567023b9703e2c404894ce362e98b78540fffb73eb0908",
                      "value": "cd83bd788807c4ec304cc17b6b773b6ad4a68ad0ca6244ecaa0bf60f2abe1b19"
                    },
                    "mtp": {
                      "existence": true,
                      "siblings": [],
                      "nodeAux": null
                    },
                    "authCoreClaim": "cca3371a6cb1b715004407e325bd993c...(truncated)",
                    "credentialStatus": {
                      "id": "https://rhs-staging.polygonid.me/node?state=cd83bd788807c4ec304cc17b6b773b6ad4a68ad0ca6244ecaa0bf60f2abe1b19",
                      "type": "Iden3ReverseSparseMerkleTreeProof",
                      "revocationNonce": 0
                    }
                  },
                  "coreClaim": "58aa9e5a86a0c14d8bca91d04c08dc30...(truncated)",
                  "signature": "cb30f31a2bcec895ba7d4c70df1eaf81588c99d6ae09c3b64ce67c8239aa8c8f...(truncated)"
                }
              ]
            }
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "object",
            "properties": {
              "credentialExchangeId": {
                "type": "string",
                "format": "uuid",
                "description": "Unique identifier for this credential exchange session."
              },
              "credentialType": {
                "type": "string",
                "enum": [
                  "jsonld-sig"
                ],
                "description": "Polygon-specific credential proof type."
              },
              "state": {
                "type": "string",
                "enum": [
                  "pending",
                  "done",
                  "abandoned"
                ],
                "description": "Credential exchange state."
              },
              "revoked": {
                "type": "boolean",
                "description": "Whether this credential has been revoked via the Iden3 Reverse Sparse Merkle Tree."
              },
              "requestType": {
                "type": "string",
                "enum": [
                  "credential_exchange_request",
                  "presentation_exchange_request",
                  "did_exchange"
                ],
                "description": "Type of Iden3comm exchange that initiated this credential offer."
              },
              "createdAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp when this credential exchange was created."
              },
              "updatedAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp of the most recent update."
              },
              "credentialOfferUrl": {
                "type": "string",
                "format": "url",
                "description": "Hovi universal app link encapsulating the credential offer for mobile wallet deep linking."
              },
              "credentialOfferUri": {
                "type": "string",
                "description": "Iden3comm deep-link URI (`iden3comm://?i_m=...`) for wallet QR scanning to claim the credential."
              },
              "credential": {
                "type": "object",
                "description": "The issued W3C JSON-LD Verifiable Credential with Iden3 BJJSignature2021 proof. Present when `state` is `done`.",
                "properties": {
                  "id": {
                    "type": "string",
                    "description": "Unique URN identifier for this credential instance (e.g., `urn:d5052970-901b-4693-a920-e41b4f1da749`)."
                  },
                  "@context": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "JSON-LD `@context` URLs. Includes W3C VC base context, Iden3 proofs context, and the IPFS-hosted schema context."
                  },
                  "type": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "Credential type array (e.g., `[\"VerifiableCredential\", \"University Degree Record\"]`)."
                  },
                  "credentialSubject": {
                    "type": "object",
                    "description": "Claim values embedded in the credential. The `id` field holds the holder's `did:iden3:polygon:amoy` DID."
                  },
                  "issuer": {
                    "type": "string",
                    "description": "Issuer's `did:iden3:polygon:amoy` DID."
                  },
                  "issuanceDate": {
                    "type": "string",
                    "format": "date-time",
                    "description": "ISO 8601 timestamp of when this credential was issued."
                  },
                  "expirationDate": {
                    "type": "string",
                    "format": "date-time",
                    "nullable": true,
                    "description": "ISO 8601 expiry date. `null` if the credential does not expire."
                  },
                  "credentialSchema": {
                    "type": "object",
                    "description": "Reference to the JSON schema document for this credential type.",
                    "properties": {
                      "id": {
                        "type": "string",
                        "format": "url",
                        "description": "IPFS-hosted URL of the JSON schema document."
                      },
                      "type": {
                        "type": "string",
                        "enum": [
                          "JsonSchema2023"
                        ],
                        "description": "Schema type identifier."
                      }
                    }
                  },
                  "credentialStatus": {
                    "type": "object",
                    "description": "Iden3 revocation status endpoint for this credential.",
                    "properties": {
                      "id": {
                        "type": "string",
                        "format": "url",
                        "description": "Polygon ID Reverse Hash Service URL for revocation state lookup."
                      },
                      "type": {
                        "type": "string",
                        "enum": [
                          "Iden3ReverseSparseMerkleTreeProof"
                        ],
                        "description": "Iden3 revocation proof type."
                      },
                      "revocationNonce": {
                        "type": "number",
                        "description": "Unique nonce for this credential in the issuer's Sparse Merkle Tree."
                      }
                    }
                  },
                  "proof": {
                    "type": "array",
                    "description": "Cryptographic proof array. Contains one BJJSignature2021 proof.",
                    "items": {
                      "type": "object",
                      "properties": {
                        "type": {
                          "type": "string",
                          "enum": [
                            "BJJSignature2021"
                          ],
                          "description": "Iden3 Baby JubJub signature proof type."
                        },
                        "issuerData": {
                          "type": "object",
                          "description": "Issuer's identity state data at the time of issuance.",
                          "properties": {
                            "id": {
                              "type": "string",
                              "description": "Issuer's `did:iden3:polygon:amoy` DID."
                            },
                            "state": {
                              "type": "object",
                              "description": "Issuer's identity state tree roots at issuance time.",
                              "properties": {
                                "rootOfRoots": {
                                  "type": "string",
                                  "description": "Root of roots tree root hash."
                                },
                                "revocationTreeRoot": {
                                  "type": "string",
                                  "description": "Revocation tree root hash."
                                },
                                "claimsTreeRoot": {
                                  "type": "string",
                                  "description": "Claims tree root hash."
                                },
                                "value": {
                                  "type": "string",
                                  "description": "Composite identity state hash."
                                }
                              }
                            },
                            "mtp": {
                              "type": "object",
                              "description": "Merkle Tree Proof of the issuer state.",
                              "properties": {
                                "existence": {
                                  "type": "boolean",
                                  "description": "Whether the leaf exists in the tree."
                                },
                                "siblings": {
                                  "type": "array",
                                  "items": {
                                    "type": "string"
                                  },
                                  "description": "Sibling nodes for the MTP path."
                                },
                                "nodeAux": {
                                  "type": "object",
                                  "nullable": true,
                                  "description": "Auxiliary node data for non-existence proofs."
                                }
                              }
                            },
                            "authCoreClaim": {
                              "type": "string",
                              "description": "Hex-encoded issuer auth core claim used for BJJSignature2021 verification."
                            },
                            "credentialStatus": {
                              "type": "object",
                              "description": "Issuer's own credential status reference.",
                              "properties": {
                                "id": {
                                  "type": "string",
                                  "format": "url",
                                  "description": "Polygon ID Reverse Hash Service URL."
                                },
                                "type": {
                                  "type": "string",
                                  "enum": [
                                    "Iden3ReverseSparseMerkleTreeProof"
                                  ],
                                  "description": "Iden3 revocation proof type."
                                },
                                "revocationNonce": {
                                  "type": "number",
                                  "description": "Revocation nonce for the issuer auth claim."
                                }
                              }
                            }
                          }
                        },
                        "coreClaim": {
                          "type": "string",
                          "description": "Hex-encoded Iden3 core claim — the canonical binary representation of the credential."
                        },
                        "signature": {
                          "type": "string",
                          "description": "Hex-encoded BJJSignature2021 signature over the core claim."
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "IssueJsonLdCredentialResponse": {
        "title": "Issue JSON-LD Credential Response",
        "type": "object",
        "description": "Returned after successfully issuing a JSON-LD Verifiable Credential via the Iden3 credential offer protocol. The holder claims the credential by scanning the `credentialOfferUri` (`iden3comm://`) or the `credentialOfferUrl` deep link with a Polygon ID-compatible wallet.",
        "example": {
          "success": true,
          "response": {
            "credentialExchangeId": "cf37f0fd-47a0-4f50-869f-b162c61a7270",
            "credentialType": "jsonld-sig",
            "credentialOfferUri": "iden3comm://?i_m=eyJpZCI6ImNmMzdmMGZkLTQ3YTAtNGY1MC04NjlmLWIxNjJjNjFhNzI3MCIsInRoaWQiOiJjZjM3ZjBmZC00N2EwLTRmNTAtODY5Zi1iMTYyYzYxYTcyNzAi...(truncated)",
            "credentialOfferUrl": "https://hovi.id/credential?data=eyJ1cmkiOiJpZGVuM2NvbW06Ly8...(truncated)",
            "createdAt": "2024-08-05T10:58:05.907Z",
            "updatedAt": "2024-08-05T10:58:05.907Z",
            "credentialOfferRequest": {
              "id": "cf37f0fd-47a0-4f50-869f-b162c61a7270",
              "thid": "cf37f0fd-47a0-4f50-869f-b162c61a7270",
              "typ": "application/iden3comm-plain-json",
              "type": "https://iden3-communication.io/credentials/1.0/offer",
              "from": "did:iden3:polygon:amoy:2qQSaniB8hK6VRqwJVy5ch56JfYNAGFXKzKj81nQkk",
              "to": "did:iden3:polygon:amoy:2qWFZnE6b4NQRmWpeVAaHwMGYv2ccYNoLDakLX1LiT",
              "body": {
                "url": "https://polygon-agent.hovi.id/credential/issue-credential/cf37f0fd-47a0-4f50-869f-b162c61a7270",
                "credentials": [
                  {
                    "id": "urn:d5052970-901b-4693-a920-e41b4f1da749",
                    "description": ""
                  }
                ]
              }
            },
            "credential": {
              "id": "urn:d5052970-901b-4693-a920-e41b4f1da749",
              "@context": [
                "https://www.w3.org/2018/credentials/v1",
                "https://schema.iden3.io/core/jsonld/iden3proofs.jsonld",
                "https://hovi.id/schemas/QmPxUiou4B8A5ee8udcfY1GUxU4CehTi8ZtuSh1wivhqmx"
              ],
              "type": [
                "VerifiableCredential",
                "University Degree Record"
              ],
              "credentialSubject": {
                "university": {
                  "batch": {
                    "passingYear": 2021
                  },
                  "branch": "KHI"
                },
                "fullName": "John Doe",
                "id": "did:iden3:polygon:amoy:2qWFZnE6b4NQRmWpeVAaHwMGYv2ccYNoLDakLX1LiT",
                "type": "University Degree Record"
              },
              "issuer": "did:iden3:polygon:amoy:2qQSaniB8hK6VRqwJVy5ch56JfYNAGFXKzKj81nQkk",
              "issuanceDate": "2024-08-05T10:57:54.845Z",
              "credentialSchema": {
                "id": "https://hovi.id/schemas/QmRF7nnhYTsWu8sqA2jeLWbWP9LuuARS9RrWsL2akvwD7v",
                "type": "JsonSchema2023"
              },
              "credentialStatus": {
                "id": "https://rhs-staging.polygonid.me/node?state=cd83bd788807c4ec304cc17b6b773b6ad4a68ad0ca6244ecaa0bf60f2abe1b19",
                "type": "Iden3ReverseSparseMerkleTreeProof",
                "revocationNonce": 4215561986
              },
              "proof": [
                {
                  "type": "BJJSignature2021",
                  "coreClaim": "58aa9e5a86a0c14d8bca91d04c08dc30...(truncated)",
                  "signature": "cb30f31a2bcec895ba7d4c70df1eaf81588c99d6ae09c3b64ce67c8239aa8c8f...(truncated)"
                }
              ]
            }
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the credential was successfully issued."
          },
          "response": {
            "type": "object",
            "properties": {
              "credentialExchangeId": {
                "type": "string",
                "format": "uuid",
                "description": "Hovi-assigned UUID for this credential exchange session."
              },
              "credentialType": {
                "type": "string",
                "enum": [
                  "jsonld-sig"
                ],
                "description": "Polygon-specific credential proof type."
              },
              "credentialOfferUri": {
                "type": "string",
                "description": "Iden3comm deep-link URI (`iden3comm://?i_m=...`) for wallet QR scanning to claim the credential."
              },
              "credentialOfferUrl": {
                "type": "string",
                "format": "url",
                "description": "Hovi universal app link encapsulating the credential offer for mobile wallet deep linking."
              },
              "createdAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp when this credential exchange was created."
              },
              "updatedAt": {
                "type": "string",
                "format": "date-time",
                "description": "ISO 8601 timestamp of the most recent update."
              },
              "credentialOfferRequest": {
                "type": "object",
                "description": "The Iden3comm credential offer message sent to the holder wallet.",
                "properties": {
                  "id": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Unique message ID of the credential offer."
                  },
                  "thid": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Thread ID for this credential exchange."
                  },
                  "typ": {
                    "type": "string",
                    "enum": [
                      "application/iden3comm-plain-json"
                    ],
                    "description": "Iden3comm content type."
                  },
                  "type": {
                    "type": "string",
                    "enum": [
                      "https://iden3-communication.io/credentials/1.0/offer"
                    ],
                    "description": "Iden3comm credential offer message type URI."
                  },
                  "from": {
                    "type": "string",
                    "description": "Issuer's `did:iden3:polygon:amoy` DID."
                  },
                  "to": {
                    "type": "string",
                    "description": "Holder's `did:iden3:polygon:amoy` DID."
                  },
                  "body": {
                    "type": "object",
                    "properties": {
                      "url": {
                        "type": "string",
                        "format": "url",
                        "description": "Polygon agent fetch URL the holder wallet calls to retrieve the signed credential."
                      },
                      "credentials": {
                        "type": "array",
                        "description": "Array of credential references included in this offer.",
                        "items": {
                          "type": "object",
                          "properties": {
                            "id": {
                              "type": "string",
                              "description": "URN identifier of the credential being offered."
                            },
                            "description": {
                              "type": "string",
                              "description": "Optional description of the offered credential."
                            }
                          }
                        }
                      }
                    }
                  }
                }
              },
              "credential": {
                "type": "object",
                "description": "The issued W3C JSON-LD Verifiable Credential with Iden3 BJJSignature2021 proof.",
                "properties": {
                  "id": {
                    "type": "string",
                    "description": "URN identifier for this credential instance."
                  },
                  "@context": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "JSON-LD `@context` URLs."
                  },
                  "type": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "Credential type array."
                  },
                  "credentialSubject": {
                    "type": "object",
                    "description": "Claim values and holder `id` (`did:iden3:polygon:amoy` DID)."
                  },
                  "issuer": {
                    "type": "string",
                    "description": "Issuer's `did:iden3:polygon:amoy` DID."
                  },
                  "issuanceDate": {
                    "type": "string",
                    "format": "date-time",
                    "description": "ISO 8601 issuance timestamp."
                  },
                  "credentialSchema": {
                    "type": "object",
                    "properties": {
                      "id": {
                        "type": "string",
                        "format": "url",
                        "description": "IPFS-hosted JSON schema URL."
                      },
                      "type": {
                        "type": "string",
                        "enum": [
                          "JsonSchema2023"
                        ],
                        "description": "Schema type identifier."
                      }
                    }
                  },
                  "credentialStatus": {
                    "type": "object",
                    "properties": {
                      "id": {
                        "type": "string",
                        "format": "url",
                        "description": "Polygon ID Reverse Hash Service URL for revocation state."
                      },
                      "type": {
                        "type": "string",
                        "enum": [
                          "Iden3ReverseSparseMerkleTreeProof"
                        ],
                        "description": "Iden3 revocation proof type."
                      },
                      "revocationNonce": {
                        "type": "number",
                        "description": "Revocation nonce for this credential."
                      }
                    }
                  },
                  "proof": {
                    "type": "array",
                    "description": "Iden3 BJJSignature2021 proof array.",
                    "items": {
                      "type": "object",
                      "properties": {
                        "type": {
                          "type": "string",
                          "enum": [
                            "BJJSignature2021"
                          ],
                          "description": "Baby JubJub signature proof type."
                        },
                        "coreClaim": {
                          "type": "string",
                          "description": "Hex-encoded Iden3 core claim."
                        },
                        "signature": {
                          "type": "string",
                          "description": "Hex-encoded BJJSignature2021 signature."
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "getConnectionBase64": {
        "title": "Get Connection Base64 Request Body",
        "type": "object",
        "description": "Request body for retrieving the Base64-encoded connection invitation payload by invitation ID.",
        "required": [
          "invitationId"
        ],
        "properties": {
          "invitationId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the connection invitation to retrieve.",
            "example": "e53e1006-5ba3-4656-b1b0-d154d2ec6f5d"
          }
        }
      },
      "deleteConnection": {
        "title": "Delete Connection Request Body",
        "type": "object",
        "description": "Request body for deleting a specific connection record.",
        "required": [
          "connectionId"
        ],
        "properties": {
          "connectionId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the connection to delete.",
            "example": "89c02ee6-c60f-4e2c-b762-45810a566376"
          }
        }
      },
      "createTenant": {
        "title": "Create Tenant Request Body",
        "type": "object",
        "description": "Request body for creating a new organization (tenant). Auto-provisions a `did:iden3:polygon:amoy` DID and optional webhook endpoints.",
        "required": [
          "name",
          "label",
          "secret"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "Human-readable name of the organization.",
            "example": "Acme Corp"
          },
          "label": {
            "type": "string",
            "description": "Short identifier label for this organization.",
            "example": "acme-corp"
          },
          "secret": {
            "type": "string",
            "description": "Secret passphrase for organization management operations (rotate key, delete).",
            "example": "acme-corp-secret"
          },
          "imageUrl": {
            "type": "string",
            "format": "url",
            "description": "Optional URL of the organization's logo image.",
            "example": "https://acme-corp.com/logo.png"
          },
          "webhooks": {
            "type": "array",
            "description": "Optional array of webhook URLs to register during tenant creation.",
            "items": {
              "type": "string",
              "format": "url"
            },
            "example": [
              "https://acme-corp.com/webhook1",
              "https://acme-corp.com/webhook2"
            ]
          }
        }
      },
      "updateTenant": {
        "title": "Update Tenant",
        "type": "object",
        "description": "The data required to update an organization's (tenant's) display settings. All fields are optional only the fields provided will be updated.",
        "example": {
          "label": "acme-corp-updated",
          "imageUrl": "https://new-acme-corp.com/new-logo.png"
        },
        "properties": {
          "label": {
            "type": "string",
            "example": "acme-corp-updated",
            "description": "Updated short slug label for the organization (shown in DIDComm connection invitations)."
          },
          "imageUrl": {
            "type": "string",
            "format": "url",
            "example": "https://new-acme-corp.com/new-logo.png",
            "description": "URL pointing to the organization logo (the image shown for this organization in the dashboard)."
          }
        }
      },
      "deleteTenant": {
        "title": "Delete Tenant Request Body",
        "type": "object",
        "description": "Request body for deleting an organization and all its associated resources. This action is irreversible.",
        "required": [
          "organizationSecret"
        ],
        "properties": {
          "organizationSecret": {
            "type": "string",
            "description": "Secret passphrase provided during tenant creation. Required to authorize deletion.",
            "example": "acme-corp-secret"
          }
        }
      },
      "rotateKey": {
        "title": "Rotate Access Token Request Body",
        "type": "object",
        "description": "Request body for rotating the organization's Ecosystem API Key. The previous token is immediately invalidated.",
        "required": [
          "accessToken",
          "organizationSecret"
        ],
        "properties": {
          "accessToken": {
            "type": "string",
            "description": "Current organization access token (JWT) to be rotated.",
            "example": "eyJhbGciOiJIUzI1NiJ9.ZXlKMFpXNWhiblJKWkNJNklt...(truncated)"
          },
          "organizationSecret": {
            "type": "string",
            "description": "Organization secret passphrase. Required to authorize token rotation.",
            "example": "acme-corp-secret"
          }
        }
      },
      "getWebhook": {
        "title": "Get Webhook Request Body",
        "type": "object",
        "description": "Request body for retrieving a specific webhook by ID.",
        "required": [
          "webhookId"
        ],
        "properties": {
          "webhookId": {
            "type": "string",
            "description": "Unique identifier of the webhook to retrieve.",
            "example": "7d3aae8bfbe4b8472511db2a957158e8"
          }
        }
      },
      "addWebhook": {
        "title": "Add Webhook Request Body",
        "type": "object",
        "description": "Creates a webhook endpoint for receiving Hovi event notifications. Hovi automatically generates a signing secret and returns it in the response. Store this secret securely and use it to verify incoming webhook requests. Each request includes `x-webhook-timestamp` and `x-webhook-signature`. The signature is generated using HMAC-SHA256 over `{timestamp}.{rawBody}`. See the Webhooks guide for complete verification instructions. [See more](https://docs.hovi.id/api-guide/business-wallet-api/webhooks)",
        "required": [
          "webhookUrl"
        ],
        "properties": {
          "webhookUrl": {
            "type": "string",
            "format": "url",
            "description": "Publicly accessible HTTP(S) endpoint URL that will receive Hovi event notification POST requests. Must respond with a 2xx status code within the timeout window.",
            "example": "https://acme-corp.com/webhook1"
          }
        },
        "example": {
          "webhookUrl": "https://acme-corp.com/webhook1"
        }
      },
      "deleteWebhook": {
        "title": "Delete Webhook Request Body",
        "type": "object",
        "description": "Request body for deregistering a webhook endpoint.",
        "required": [
          "webhookId"
        ],
        "properties": {
          "webhookId": {
            "type": "string",
            "description": "Unique identifier of the webhook to delete.",
            "example": "7d3aae8bfbe4b8472511db2a957158e8"
          }
        }
      },
      "rotateWebhookSecret": {
        "title": "Rotate Webhook Secret Request Body",
        "type": "object",
        "description": "Request body for rotating the signing secret of an existing webhook. A signing secret is generated automatically.",
        "required": [
          "webhookId"
        ],
        "properties": {
          "webhookId": {
            "type": "string",
            "description": "Unique identifier of the webhook whose secret should be rotated.",
            "example": "7d3aae8bfbe4b8472511db2a957158e8"
          }
        }
      },
      "RotateWebhookSecretResponse": {
        "title": "Rotate Webhook Secret Response",
        "type": "object",
        "description": "Returned after successfully rotating a webhook signing secret.",
        "example": {
          "success": true,
          "response": {
            "webhookId": "7d3aae8bfbe4b8472511db2a957158e8",
            "webhookSecret": "your-new-webhook-secret"
          }
        },
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Indicates if the operation was successful."
          },
          "response": {
            "type": "object",
            "properties": {
              "webhookId": {
                "type": "string",
                "description": "Unique identifier of the webhook."
              },
              "webhookSecret": {
                "type": "string",
                "description": "Newly generated webhook signing secret."
              }
            }
          }
        }
      },
      "createJsonLdCredentialTemplate": {
        "title": "Create JSON-LD Credential Template Request Body",
        "type": "object",
        "description": "Request body for creating a JSON-LD credential template. The schema context document is published to IPFS and the template is stored for use in Iden3 credential issuance flows. Attributes support primitive types (`string`, `integer`, `double`, `boolean`) and nested `object` types for structured claim hierarchies.",
        "required": [
          "name",
          "version",
          "description",
          "attributes",
          "schemaType",
          "privadoCredentialType"
        ],
        "properties": {
          "categoryId": {
            "type": "string",
            "format": "uuid",
            "description": "Optional industry or sector category UUID to classify this credential template within Hovi Studio (e.g., healthcare, education). If omitted, the template is created without a category.",
            "example": "9636b597-cbe2-492a-bf92-87641729e6e4"
          },
          "name": {
            "type": "string",
            "description": "Human-readable name of the credential template as it will appear in Hovi Studio and the holder's wallet (e.g., `\"Patient ID 2\"`).",
            "example": "Patient ID 2"
          },
          "version": {
            "type": "string",
            "description": "Semantic version string for this template (e.g., `\"1.0.1\"`). Each unique `name` and `version` combination results in a distinct schema context document published to IPFS. Increment the version to publish schema changes since published schemas are immutable.",
            "example": "1.0.1"
          },
          "image": {
            "type": "string",
            "format": "url",
            "description": "Optional URL of the credential card background image displayed in the holder's wallet when this credential is issued and stored.",
            "example": "https://acme-corp.com/patient.png"
          },
          "description": {
            "type": "string",
            "description": "Plain-text description of what this credential represents (e.g., `\"Patient ID Card\"`).",
            "example": "Patient ID Card"
          },
          "attributes": {
            "type": "array",
            "description": "Ordered list of `credentialSubject` claim field definitions for this JSON-LD credential template. Supports primitive types (`string`, `integer`, `double`, `boolean`) and structured `object` types with nested `attributes` for multi-level claim hierarchies (e.g., `address.street`, `organization.department.departmentName`).",
            "items": {
              "type": "object",
              "description": "A single claim field definition. Use `type: \"object\"` with a nested `attributes` array to define structured multi-level claim hierarchies.",
              "properties": {
                "name": {
                  "type": "string",
                  "maxLength": 50,
                  "description": "Programmatic field identifier used as the key in the JSON-LD `credentialSubject` (e.g., `\"fullName\"`, `\"postalCode\"`). Must be camelCase and unique within its parent attribute scope.",
                  "example": "fullName"
                },
                "type": {
                  "type": "string",
                  "enum": [
                    "string",
                    "integer",
                    "double",
                    "boolean",
                    "object"
                  ],
                  "description": "Data type of this claim field. `string` — plain text value. `integer` — whole number. `double` — floating-point number. `boolean` — true/false flag. `object` — structured nested claim; must include a child `attributes` array defining its sub-fields.",
                  "example": "string"
                },
                "label": {
                  "type": "string",
                  "maxLength": 100,
                  "description": "Human-readable display label for this claim field shown in the holder's wallet UI and Hovi Studio (e.g., `\"Full Name\"`, `\"Postal Code\"`).",
                  "example": "Full Name"
                },
                "description": {
                  "type": "string",
                  "maxLength": 200,
                  "description": "Semantic description of this claim field explaining what data it represents (e.g., `\"Full legal name\"`, `\"ZIP or postal code\"`).",
                  "example": "Full legal name"
                },
                "required": {
                  "type": "boolean",
                  "description": "Whether this claim field must be provided with a value during credential issuance. `true` — the field is mandatory and issuance will fail if omitted. `false` — the field is optional and may be left unpopulated.",
                  "example": true
                },
                "attributes": {
                  "type": "array",
                  "description": "Nested sub-claim definitions for `object`-type attributes. Required when `type` is `\"object\"`. Supports recursive nesting — sub-attributes may themselves be of `type: \"object\"` with their own `attributes` array (e.g., `organization.department.departmentName`).",
                  "items": {
                    "type": "object",
                    "description": "A nested sub-claim field definition following the same structure as a top-level attribute (`name`, `type`, `label`, `description`, `required`, and optionally a further nested `attributes` array for deeply nested object hierarchies)."
                  }
                }
              }
            }
          },
          "schemaType": {
            "type": "string",
            "description": "The JSON-LD `@type` value embedded in all credentials issued from this template (e.g., `\"Patient Record\"`). This value is encoded into the IPFS-published schema context document and becomes the credential's semantic type identifier used by verifiers during presentation validation.",
            "example": "Patient Record"
          },
          "credentialTheme": {
            "$ref": "#/components/schemas/CredentialTheme",
            "description": "Optional visual rendering theme for the credential card displayed in Polygon ID-compatible wallets. Defines the card title, description, text colors, background image, and logo. When omitted, the wallet renders the credential using default styling."
          },
          "privadoCredentialType": {
            "type": "string",
            "description": "The Polygon ecosystem credential type identifier for this template (e.g., `\"Patient Record\"`). Used by the Polygon network to categorize and route credentials within its ecosystem. Typically matches `schemaType` but is stored and referenced independently within the Polygon registry.",
            "example": "Patient Record"
          }
        }
      },
      "importJsonLdCredentialTemplate": {
        "title": "Import JSON-LD Credential Template Request Body",
        "type": "object",
        "description": "Request body for importing an existing JSON-LD credential template by referencing a publicly hosted schema URL.",
        "required": [
          "schemaUrl"
        ],
        "properties": {
          "categoryId": {
            "type": "string",
            "format": "uuid",
            "description": "Optional industry/sector category UUID for the imported template.",
            "example": "2e5f483f-8970-4c5e-baf7-991ff24c120d"
          },
          "schemaUrl": {
            "type": "string",
            "format": "url",
            "description": "Public URL of the JSON-LD schema document to import (e.g., IPFS gateway URL).",
            "example": "https://hovi.id/schemas/QmRF7nnhYTsWu8sqA2jeLWbWP9LuuARS9RrWsL2akvwD7v"
          },
          "image": {
            "type": "string",
            "format": "url",
            "description": "Optional URL of the credential card image displayed in the holder's wallet.",
            "example": "https://acme-corp.com/patient.png"
          }
        }
      },
      "getTemplateByCredentialTemplateId": {
        "title": "Get Credential Template By ID Request Body",
        "type": "object",
        "description": "Request body for retrieving a specific credential template by its UUID.",
        "required": [
          "credentialTemplateId"
        ],
        "properties": {
          "credentialTemplateId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the credential template to retrieve.",
            "example": "ae5717a4-7f04-46a2-bf42-591cd226a7e2"
          }
        }
      },
      "getConnectionById": {
        "title": "Get Connection By ID Request Body",
        "type": "object",
        "description": "Request body for retrieving a specific connection record by its UUID.",
        "required": [
          "connectionId"
        ],
        "properties": {
          "connectionId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the connection to retrieve.",
            "example": "89c02ee6-c60f-4e2c-b762-45810a566376"
          }
        }
      },
      "getConnectionsByInvitationId": {
        "title": "Get Connections By Invitation ID Request Body",
        "type": "object",
        "description": "Request body for listing all connection records associated with a specific invitation UUID.",
        "required": [
          "inviationId"
        ],
        "properties": {
          "inviationId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the invitation to query connections for.",
            "example": "e53e1006-5ba3-4656-b1b0-d154d2ec6f5d"
          }
        }
      },
      "createConnectionInvitation": {
        "title": "Create Connection Invitation Request Body",
        "type": "object",
        "description": "Request body for generating an Iden3comm connection invitation. The `invitationUri` (`iden3comm://`) is encoded into a QR code or deep link for a Polygon ID-compatible holder wallet to scan.",
        "required": [
          "label"
        ],
        "properties": {
          "label": {
            "type": "string",
            "description": "Human-readable label for this connection invitation.",
            "example": "Acme Corp Connection"
          },
          "alias": {
            "type": "string",
            "description": "Optional alias name for the connection.",
            "example": "acme-connection"
          },
          "autoAcceptConnection": {
            "type": "boolean",
            "description": "Whether to automatically accept incoming connection responses without manual approval.",
            "example": true
          },
          "multiUseInvitation": {
            "type": "boolean",
            "description": "`true` — reusable invitation; multiple wallets may connect. `false` — single-use, expires after first connection.",
            "example": false
          },
          "domain": {
            "type": "string",
            "description": "Optional domain name associated with this connection invitation.",
            "example": "xyz-domain.com"
          },
          "imageUrl": {
            "type": "string",
            "format": "url",
            "description": "Optional URL of an image displayed on the connection invitation screen.",
            "example": "https://acme-corp.com/connection.png"
          }
        }
      },
      "getCredentialById": {
        "title": "Get Credential By ID Request Body",
        "type": "object",
        "description": "Request body for retrieving a specific credential exchange record by its UUID.",
        "required": [
          "credentialExchangeId"
        ],
        "properties": {
          "credentialExchangeId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the credential exchange to retrieve.",
            "example": "cf37f0fd-47a0-4f50-869f-b162c61a7270"
          }
        }
      },
      "issueJsonLdCredential": {
        "title": "Issue JSON-LD Credential Request Body",
        "type": "object",
        "description": "Request body for issuing a JSON-LD Verifiable Credential to a holder via the Iden3 credential offer protocol. The holder claims the credential by scanning the `credentialOfferUri` with a Polygon ID-compatible wallet.",
        "required": [
          "connectionId",
          "credentialTemplateId",
          "credentialValues"
        ],
        "properties": {
          "connectionId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the established Iden3comm connection to the holder's wallet.",
            "example": "89c02ee6-c60f-4e2c-b762-45810a566376"
          },
          "credentialTemplateId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the credential template to use for issuance.",
            "example": "ae5717a4-7f04-46a2-bf42-591cd226a7e2"
          },
          "credentialValues": {
            "type": "object",
            "description": "Key-value pairs mapping claim field names (from the template) to their values. Supports nested objects.",
            "example": {
              "name": "John Doe",
              "age": "30"
            }
          },
          "comment": {
            "type": "string",
            "description": "Optional plain-text comment attached to the credential offer.",
            "example": "This is a comment"
          }
        }
      },
      "getTemplateByVerificationTemplateId": {
        "title": "Get Verification Template By ID Request Body",
        "type": "object",
        "description": "Request body for retrieving a specific verification template by its UUID.",
        "required": [
          "verificationTemplateId"
        ],
        "properties": {
          "verificationTemplateId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the verification template to retrieve.",
            "example": "796dbd9d-8b61-4180-b94d-df4a4e138378"
          }
        }
      },
      "createJsonLdVerificationTemplate": {
        "title": "Create JSON-LD Verification Template Request Body",
        "type": "object",
        "description": "Request body for creating a JSON-LD verification template. The `conditions` array maps to Iden3 `privadoProofScopes` — `credentialAtomicQuerySigV2` circuit conditions defining the ZK proof request.",
        "required": [
          "name",
          "version",
          "description"
        ],
        "properties": {
          "categoryId": {
            "type": "string",
            "format": "uuid",
            "description": "Optional industry/sector category UUID for this verification template.",
            "example": "9636b597-cbe2-492a-bf92-87641729e6e4"
          },
          "contextUrl": {
            "type": "string",
            "format": "url",
            "description": "Optional JSON-LD `@context` URL for the credential schema being verified (e.g., IPFS gateway URL).",
            "example": "https://hovi.id/schemas/QmPxUiou4B8A5ee8udcfY1GUxU4CehTi8ZtuSh1wivhqmx"
          },
          "name": {
            "type": "string",
            "description": "Human-readable name of the verification template.",
            "example": "Patient ID Verification"
          },
          "version": {
            "type": "string",
            "description": "Semantic version string for this template.",
            "example": "1.0.1"
          },
          "description": {
            "type": "string",
            "description": "Plain-text description of what this template verifies.",
            "example": "Patient ID verification template"
          },
          "image": {
            "type": "string",
            "format": "url",
            "description": "Optional URL of an image displayed on the proof request screen.",
            "example": "https://acme-corp.com/patient.png"
          },
          "conditions": {
            "type": "array",
            "description": "Proof condition array. Each condition maps to one Iden3 `privadoProofScope` — a `credentialAtomicQuerySigV2` circuit query defining the ZK proof requirement.",
            "items": {
              "type": "object",
              "properties": {
                "allowedIssuers": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  },
                  "description": "Accepted issuer DIDs. `[\"*\"]` accepts credentials from any issuer.",
                  "example": [
                    "*"
                  ]
                },
                "credentialSubject": {
                  "type": "object",
                  "description": "Iden3 query conditions on credential subject fields. Supports `$eq`, `$in`, `$gt`, `$lt`, `$gte`, `$lte` operators on dot-notation field paths (e.g., `university.batch.passingYear`).",
                  "example": {
                    "university.batch.passingYear": {
                      "$in": [
                        2000,
                        2021,
                        2022
                      ]
                    }
                  }
                }
              }
            },
            "example": [
              {
                "allowedIssuers": [
                  "*"
                ],
                "credentialSubject": {
                  "university.batch.passingYear": {
                    "$in": [
                      2000,
                      2021,
                      2022
                    ]
                  }
                }
              },
              {
                "allowedIssuers": [
                  "*"
                ],
                "credentialSubject": {
                  "fullName": {
                    "$eq": "John Doe"
                  }
                }
              }
            ]
          },
          "restrictions": {
            "type": "object",
            "description": "Optional restrictions narrowing the acceptable credential types for this verification template.",
            "properties": {
              "credentialTemplateId": {
                "type": "string",
                "format": "uuid",
                "description": "Optional UUID of a specific credential template to restrict verification to.",
                "example": "ae5717a4-7f04-46a2-bf42-591cd226a7e2"
              },
              "schemaType": {
                "type": "string",
                "description": "Optional JSON-LD `@type` value to restrict verification to (e.g., `\"Patient Record\"`).",
                "example": "Patient Record"
              }
            }
          }
        }
      },
      "getProofRequestById": {
        "title": "Get Proof Request By ID Request Body",
        "type": "object",
        "description": "Request body for retrieving a specific proof exchange record by its UUID.",
        "required": [
          "proofExchangeId"
        ],
        "properties": {
          "proofExchangeId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the proof exchange to retrieve.",
            "example": "acd42bba-891b-4577-9218-a51ce3f67e37"
          }
        }
      },
      "getProofResponseById": {
        "title": "Get Proof Response By Presentation ID Request Body",
        "type": "object",
        "description": "Request body for retrieving a specific ZK proof response by its presentation UUID.",
        "required": [
          "presentationId"
        ],
        "properties": {
          "presentationId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the presentation response to retrieve.",
            "example": "d78c9b23-427e-402c-a8d6-25bbee602597"
          }
        }
      },
      "sendProofRequest": {
        "title": "Send Proof Request Request Body",
        "type": "object",
        "description": "Request body for sending a Polygon proof request to a holder wallet. The `proofRequestUri` (`iden3comm://`) and `verificationUrl` are encoded into a QR code or deep link for the holder to scan and submit a ZK proof.",
        "required": [
          "verificationTemplateId"
        ],
        "properties": {
          "verificationTemplateId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the verification template defining the proof scopes for this request.",
            "example": "796dbd9d-8b61-4180-b94d-df4a4e138378"
          },
          "connectionId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the established Iden3comm connection to the holder's wallet.",
            "example": "89c02ee6-c60f-4e2c-b762-45810a566376"
          }
        }
      },
      "DeleteTemplateByVerificationTemplateId": {
        "title": "Delete Verification Template Request Body",
        "type": "object",
        "description": "Request body for deleting a verification template by its UUID.",
        "required": [
          "verificationTemplateId"
        ],
        "properties": {
          "verificationTemplateId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the verification template to delete.",
            "example": "9636b597-cbe2-492a-bf92-87641729e6e4"
          }
        }
      },
      "UpdateTemplateByVerificationTemplateId": {
        "title": "Update Verification Template Request Body",
        "type": "object",
        "description": "Request body for updating an existing verification template.",
        "required": [
          "verificationTemplateId"
        ],
        "properties": {
          "verificationTemplateId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the verification template to update.",
            "example": "796dbd9d-8b61-4180-b94d-df4a4e138378"
          },
          "categoryId": {
            "type": "string",
            "format": "uuid",
            "description": "Optional updated industry/sector category UUID.",
            "example": "9636b597-cbe2-492a-bf92-87641729e6e4"
          },
          "name": {
            "type": "string",
            "description": "Optional updated name.",
            "example": "Updated Verification Template Name"
          },
          "description": {
            "type": "string",
            "description": "Optional updated description.",
            "example": "Updated description"
          },
          "image": {
            "type": "string",
            "format": "url",
            "description": "Optional updated image URL.",
            "example": "https://acme-corp.com/updated-image.png"
          }
        }
      },
      "UpdateCredentialTemplate": {
        "title": "Update Credential Template Request Body",
        "type": "object",
        "description": "Request body for updating an existing credential template.",
        "required": [
          "credentialTemplateId"
        ],
        "properties": {
          "credentialTemplateId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the credential template to update.",
            "example": "9636b597-cbe2-492a-bf92-87641729e6e4"
          },
          "categoryId": {
            "type": "string",
            "format": "uuid",
            "description": "Optional updated industry/sector category UUID.",
            "example": "9636b597-cbe2-492a-bf92-87641729e6e4"
          },
          "image": {
            "type": "string",
            "format": "url",
            "description": "Optional updated credential card image URL.",
            "example": "https://brandslogos.com/wp-content/uploads/images/large/acme-logo.png"
          }
        }
      },
      "DeleteCredentialTemplate": {
        "title": "Delete Credential Template Request Body",
        "type": "object",
        "description": "Request body for deleting a credential template by its UUID.",
        "required": [
          "credentialTemplateId"
        ],
        "properties": {
          "credentialTemplateId": {
            "type": "string",
            "format": "uuid",
            "description": "UUID of the credential template to delete.",
            "example": "9636b597-cbe2-492a-bf92-87641729e6e4"
          }
        }
      },
      "PolygonConnectionCompletedWebhook": {
        "type": "object",
        "required": [
          "invitationId",
          "connectionId",
          "state",
          "isVerified",
          "id",
          "typ",
          "type",
          "thid",
          "body",
          "from",
          "to"
        ],
        "properties": {
          "invitationId": {
            "type": "string",
            "format": "uuid"
          },
          "connectionId": {
            "type": "string",
            "format": "uuid"
          },
          "state": {
            "type": "string",
            "const": "completed"
          },
          "isVerified": {
            "type": "boolean"
          },
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "typ": {
            "type": "string"
          },
          "type": {
            "type": "string",
            "format": "uri"
          },
          "thid": {
            "type": "string",
            "format": "uuid"
          },
          "body": {
            "type": "object",
            "additionalProperties": true
          },
          "from": {
            "type": "string"
          },
          "to": {
            "type": "string"
          }
        }
      },
      "PolygonCredentialIssuedWebhook": {
        "type": "object",
        "required": [
          "credentialExchangeId",
          "state",
          "isIssued",
          "id",
          "thid",
          "type",
          "typ",
          "to",
          "from",
          "body"
        ],
        "properties": {
          "credentialExchangeId": {
            "type": "string",
            "format": "uuid"
          },
          "state": {
            "type": "string",
            "const": "done"
          },
          "isIssued": {
            "type": "boolean"
          },
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "thid": {
            "type": "string",
            "format": "uuid"
          },
          "type": {
            "type": "string",
            "format": "uri"
          },
          "typ": {
            "type": "string"
          },
          "to": {
            "type": "string"
          },
          "from": {
            "type": "string"
          },
          "body": {
            "type": "object",
            "required": [
              "credential"
            ],
            "properties": {
              "credential": {
                "type": "object",
                "additionalProperties": true
              }
            }
          }
        }
      },
      "PolygonPresentationVerifiedWebhook": {
        "type": "object",
        "required": [
          "proofExchangeId",
          "presentationId",
          "state",
          "isVerified",
          "id",
          "typ",
          "type",
          "thid",
          "body",
          "from",
          "to"
        ],
        "properties": {
          "proofExchangeId": {
            "type": "string",
            "format": "uuid"
          },
          "presentationId": {
            "type": "string",
            "format": "uuid"
          },
          "state": {
            "type": "string",
            "const": "done"
          },
          "isVerified": {
            "type": "boolean"
          },
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "typ": {
            "type": "string"
          },
          "type": {
            "type": "string",
            "format": "uri"
          },
          "thid": {
            "type": "string",
            "format": "uuid"
          },
          "body": {
            "type": "object",
            "additionalProperties": true
          },
          "from": {
            "type": "string"
          },
          "to": {
            "type": "string"
          }
        }
      }
    }
  },
  "security": [
    {
      "bearerAuth": []
    }
  ],
  "webhooks": {
    "polygon-connection-completed": {
      "post": {
        "tags": [
          "Webhook Events"
        ],
        "operationId": "polygon-connection-completed",
        "summary": "Connection Established",
        "description": "Sent to the issuer organization after the external holder wallet accepts the Iden3 connection.",
        "parameters": [
          {
            "name": "x-webhook-signature",
            "in": "header",
            "description": "HMAC signature used to verify that this webhook was sent by Hovi.",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "sha256=9d8f1f2f7f4e4b28d52c1b2a1fb7d39a"
          },
          {
            "name": "x-webhook-timestamp",
            "in": "header",
            "description": "Unix timestamp included when calculating and verifying the webhook signature.",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "1786707084"
          }
        ],
        "requestBody": {
          "required": true,
          "description": "The JSON event Hovi sends to the registered webhook URL.",
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PolygonConnectionCompletedWebhook"
              },
              "example": {
                "invitationId": "c9b861cd-fa62-489d-901c-059508d7b931",
                "connectionId": "f9288340-925f-4f61-ba31-fbc353805d6a",
                "state": "completed",
                "isVerified": true,
                "id": "4334e147-b485-43f6-bed2-5affb0a339c1",
                "typ": "application/iden3-zkp-json",
                "type": "https://iden3-communication.io/authorization/1.0/response",
                "thid": "c9b861cd-fa62-489d-901c-059508d7b931",
                "body": {
                  "did_doc": {
                    "context": [
                      "https://www.w3.org/ns/did/v1"
                    ],
                    "id": "did:iden3:privado:main:2SkRo7PrbyDuUVsKTrnp1BJpxsn9fvYzBSTvwwgNxn",
                    "service": [
                      {
                        "id": "did:iden3:privado:main:2SkRo7PrbyDuUVsKTrnp1BJpxsn9fvYzBSTvwwgNxn#mobile",
                        "type": "Iden3MobileServiceV1",
                        "serviceEndpoint": "iden3comm:v0.1:callbackHandler"
                      }
                    ]
                  },
                  "message": null,
                  "scope": []
                },
                "from": "did:iden3:privado:main:2SkRo7PrbyDuUVsKTrnp1BJpxsn9fvYzBSTvwwgNxn",
                "to": "did:iden3:polygon:amoy:xBmSKGaPr3xmMamQ9eYXj3NQboswNaP94nNyDeNfs"
              }
            }
          }
        },
        "responses": {
          "2XX": {
            "description": "Webhook acknowledged successfully by the receiver. No response body is required."
          }
        }
      }
    },
    "polygon-credential-issued": {
      "post": {
        "tags": [
          "Webhook Events"
        ],
        "operationId": "polygon-credential-issued",
        "summary": "Credential Issued",
        "description": "Sent to the issuer organization after the external holder wallet accepts the JSON-LD credential.",
        "parameters": [
          {
            "name": "x-webhook-signature",
            "in": "header",
            "description": "HMAC signature used to verify that this webhook was sent by Hovi.",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "sha256=9d8f1f2f7f4e4b28d52c1b2a1fb7d39a"
          },
          {
            "name": "x-webhook-timestamp",
            "in": "header",
            "description": "Unix timestamp included when calculating and verifying the webhook signature.",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "1786707084"
          }
        ],
        "requestBody": {
          "required": true,
          "description": "The JSON event Hovi sends to the registered webhook URL.",
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PolygonCredentialIssuedWebhook"
              },
              "example": {
                "credentialExchangeId": "33faa72c-36d9-434f-9096-2f8ae25f53a2",
                "state": "done",
                "isIssued": true,
                "id": "d6ad688c-d607-4f5b-adb7-0b316b882f41",
                "thid": "d6ad688c-d607-4f5b-adb7-0b316b882f41",
                "type": "https://iden3-communication.io/credentials/1.0/issuance-response",
                "typ": "application/iden3comm-plain-json",
                "to": "did:iden3:privado:main:2SkRo7PrbyDuUVsKTrnp1BJpxsn9fvYzBSTvwwgNxn",
                "from": "did:iden3:polygon:amoy:xBmSKGaPr3xmMamQ9eYXj3NQboswNaP94nNyDeNfs",
                "body": {
                  "credential": {
                    "id": "urn:1a092624-bcf3-4d20-8529-950e27c40607",
                    "@context": [
                      "https://www.w3.org/2018/credentials/v1"
                    ],
                    "type": [
                      "VerifiableCredential",
                      "issuerCt"
                    ],
                    "issuanceDate": "2026-08-14T11:54:38.938Z",
                    "credentialSubject": {
                      "name": "234234",
                      "id": "did:iden3:privado:main:2SkRo7PrbyDuUVsKTrnp1BJpxsn9fvYzBSTvwwgNxn",
                      "type": "issuerCt"
                    },
                    "issuer": "did:iden3:polygon:amoy:xBmSKGaPr3xmMamQ9eYXj3NQboswNaP94nNyDeNfs"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "2XX": {
            "description": "Webhook acknowledged successfully by the receiver. No response body is required."
          }
        }
      }
    },
    "polygon-presentation-verified": {
      "post": {
        "tags": [
          "Webhook Events"
        ],
        "operationId": "polygon-presentation-verified",
        "summary": "Presentation Verified",
        "description": "Sent to the verifier organization after the external holder wallet submits a valid zero-knowledge proof.",
        "parameters": [
          {
            "name": "x-webhook-signature",
            "in": "header",
            "description": "HMAC signature used to verify that this webhook was sent by Hovi.",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "sha256=9d8f1f2f7f4e4b28d52c1b2a1fb7d39a"
          },
          {
            "name": "x-webhook-timestamp",
            "in": "header",
            "description": "Unix timestamp included when calculating and verifying the webhook signature.",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "1786707084"
          }
        ],
        "requestBody": {
          "required": true,
          "description": "The JSON event Hovi sends to the registered webhook URL.",
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PolygonPresentationVerifiedWebhook"
              },
              "example": {
                "proofExchangeId": "a5b64b7b-6275-4364-9683-e024272e8e64",
                "presentationId": "358cab60-253c-4612-9a9c-4deb572f5b59",
                "state": "done",
                "isVerified": true,
                "id": "cf5a56aa-e300-490e-9bb6-dee650e40f27",
                "typ": "application/iden3-zkp-json",
                "type": "https://iden3-communication.io/authorization/1.0/response",
                "thid": "a5b64b7b-6275-4364-9683-e024272e8e64",
                "body": {
                  "message": null,
                  "scope": [
                    {
                      "id": 1,
                      "circuitId": "credentialAtomicQuerySigV2",
                      "proof": {
                        "protocol": "groth16"
                      }
                    }
                  ]
                },
                "from": "did:iden3:privado:main:2SkRo7PrbyDuUVsKTrnp1BJpxsn9fvYzBSTvwwgNxn",
                "to": "did:iden3:polygon:amoy:xBmSKGaPr3xmMamQ9eYXj3NQboswNaP94nNyDeNfs"
              }
            }
          }
        },
        "responses": {
          "2XX": {
            "description": "Webhook acknowledged successfully by the receiver. No response body is required."
          }
        }
      }
    }
  }
}