Empeiria Documentation
  • Getting Started
    • Welcome to Empeiria
    • 5 minutes Quickstart
    • Tutorial: Credential Issuance & Verification
      • Overview
      • Understanding Key Concepts
      • Project Setup
      • Deploying the Issuer
      • Uploading the Credential Schema
      • Issuing Credentials
      • Frontend for Credential Issuance
      • Testing Credential Issuance
      • Deploying the Verifier
      • Setting Up the Verification Flow
      • Creating a Verification Endpoint
      • Creating a Protected Dashboard
      • Testing the Verification Flow
      • Summary & Next Steps
  • Understand
    • EVDI Architecture
    • Self-Sovereign Identity
      • Technical Foundations
      • Roles in the SSI framework
      • Protocols and Standards
  • Develop
    • One-click deployment
      • Introduction
      • Registration
      • Login
      • Creating an Issuer
      • Issuer Data Description
      • Creating a Verifier
      • Verifier Data Description
    • Issuer
      • Terminology and Concepts
      • DID Document Management
      • Schema Management
      • Issuing Credentials and Interacting With Wallets
      • Revocations
      • Security Considerations
      • Error Handling and Troubleshooting
      • Future Enhancements
      • References and Standards
      • MCP Server Integration
      • FAQ
      • API Reference
        • Token
        • Schema
        • Offering
        • Metadata
        • Credential
        • Blockchain
        • Authorization
    • Verifier
      • Terminology and Concepts
      • Architecture Overview
      • Core Responsibilities
      • Query Language
      • Client Configuration
      • Frontend Integration
      • Revocations
      • Server-Side VP Queries
      • Security Considerations
      • Error Handling and Troubleshooting
      • Future Enhancements
      • References and Standards
      • MCP Server Integration
      • FAQ
      • API Reference
        • VP Query
        • QR Code
        • Authorization
    • Wallet SDK (Coming soon)
    • Introduction to cosmwasm
  • Empe Blockchain
    • Overview
    • Chain Architecture
      • Auth
      • Authz
      • Bank
      • Distribution
      • Governance
      • Staking
      • IBC
      • DidDoc
      • Vesting
      • Minter
      • Stablefee
      • LinkedResources
    • Important links
    • Validators Guide
      • New validator
      • Hardware requirements
      • Required software installation
      • Go installation
      • Install prebuild binary
      • Install binary from source code (option B)
      • Configure a node
      • Cosmovisor setup
      • Install wasmvm
      • Sync with state-sync
      • Full state sync from archive snapshot
      • Latest snapshot
      • Run a Validator
      • Migration to v0.2.2
      • Migration to v0.3.0
      • Migration to v0.4.0
      • FAQ
  • User Guide
    • Empe DID Wallet
      • Intro
      • Download and first launch
      • Create or import did
      • Main screen overview
      • How to claim credential from issuer
      • How to use credential with verifier
      • Settings and other options
    • Keplr Wallet and Blockchain Operations
      • How to Connect Keplr Wallet
    • Ping Pub operation
    • Staking Tokens Guide
    • Voting on Governance Proposals Guide
    • Sending Tokens Guide
    • Airdrop
      • On-Chain Testnet Airdrop
      • Faucet Guide: How to Claim Testnet Tokens?
  • Appendix
    • Glossary
Powered by GitBook
On this page
  1. Develop
  2. Issuer
  3. API Reference

Credential

PreviousMetadataNextBlockchain

Update a single credential’s status bit

post

Mark a credential’s status (e.g. revoke)

Authorizations
Path parameters
idstringRequired

The credential ID to update

Responses
200
OK
400
Bad Request
application/json
401
Unauthorized
application/json
403
Forbidden
application/json
post
POST /v1/credentials/{id}/revoke HTTP/1.1
Host: api
x-client-secret: YOUR_API_KEY
Accept: */*

No content

  • POSTCreate a credential without a recipient Creates a standalone credential without specifying a recipient
  • GETGet a credential by its ID Gets a credential by its ID for the authenticated holder
  • POSTUpdate a single credential’s status bit

Get a credential by its ID Gets a credential by its ID for the authenticated holder

get

Retrieve a credential by ID

Authorizations
Path parameters
idstringRequired

The unique identifier of the credential

Responses
200
OK
application/json
400
Bad Request
application/json
401
Unauthorized
application/json
404
Not Found
application/json
get
GET /v1/credentials/{id} HTTP/1.1
Host: api
Authorization: Bearer JWT
Accept: */*
{
  "id": "d290f1ee-6c54-4b01-90e6-d701748f0851",
  "vc": {
    "@context": [
      "https://www.w3.org/2018/credentials/v1"
    ],
    "type": [
      "VerifiableCredential"
    ],
    "id": "urn:uuid:d290f1ee-6c54-4b01-90e6-d701748f0851",
    "issuer": "did:empe:0x1234567890abcdef",
    "issuanceDate": "2023-01-01T00:00:00Z"
  }
}

Create a credential without a recipient Creates a standalone credential without specifying a recipient

post

Create a standalone credential

Authorizations
Body

Request containing credential type and subject data

typestring · min: 1Required

Type of credential to be created

Example: ProofOfPurchasePattern: ^[a-zA-Z0-9_]+$
Responses
201
Created
application/json
400
Bad Request
application/json
401
Unauthorized
application/json
403
Forbidden
application/json
post
POST /v1/credentials HTTP/1.1
Host: api
Authorization: Bearer JWT
Content-Type: application/json
Accept: */*
Content-Length: 116

{
  "type": "ProofOfPurchase",
  "credential_subject": {
    "id": "did:empe:0x123456789",
    "name": "John Doe",
    "purchaseId": "12345"
  }
}
{
  "id": "d290f1ee-6c54-4b01-90e6-d701748f0851",
  "vc": {
    "@context": [
      "https://www.w3.org/2018/credentials/v1"
    ],
    "type": [
      "VerifiableCredential"
    ],
    "id": "urn:uuid:d290f1ee-6c54-4b01-90e6-d701748f0851",
    "issuer": "did:empe:0x1234567890abcdef",
    "issuanceDate": "2023-01-01T00:00:00Z"
  }
}