Sign a message
Accepts a message payload and signs it with a JWS (JSON Web Signature) using the a specific key from the DID (Decentralized Identifier) provided in the request.
Roles
Analytics Events
bearerAuthAuthorizationBearer <token>Sign message request
application/json- body
didUrl*stringThe did key that will be used to sign the message, which must supports signing. You can obtain it from the DID document DID.localMetadata.initialDidDocument.authentication[0] path.
payload*A JSON Object plaintext message
Message signed
response?SignMessageResponseapplication/jsonSigned message in a response
curl -X POST 'https://example.vii.au01.mattr.global/v1/messaging/sign' \ -H 'Content-Type: application/json' \ -d '{ "didUrl": "did:web:organization.com#2vcj3MjR4d", "payload": { "msg": "this is a message" }}'"eyJhbGciOiJFZERTQSIsImtpZCI6ImRpZDprZXk6ejZNa21mazNtMldIQlVxVm94SlZ3R1NQejVrYmFKNnpBMXRwN1JRWUJiUUdtczNoI3o2TWttZmszbTJXSEJVcVZveEpWd0dTUHo1a2JhSjZ6QTF0cDdSUVlCYlFHbXMzaCJ9.eyJtc2ciOiJUaGlzIGlzIGEgcGF5bG9hZCJ9.5E9qEmmSOMHLABAr4A9VzuNKFaO4EDo2GSCMoxQm9zsE7eCmEEuaAxtNhOUdd-Wvj64vqBBVl84XB1Yg7X9wBg"How would you rate this page?
Create credential report POST
Creates a report of credential lifecycle operations (issuance and status changes). Only CWT and mDoc credentials are included in the report.
Verify a message POST
Verifies the signature of a provided JWS (JSON Web Signature), validating that the payload has not been tampered with and verifying that the kid in the JWS header is the same as the `iss` value in the Request Object. One use case for verifying a JWS with a DID is when the Mobile Wallet App sends a Request Object to an OpenID Provider as part of the Authorization Code Flow (as per https://openid.net/specs/openid-connect-core-1_0-final.html#RequestObject). The Request Object is wrapped in a JWS with a signature that is generated from the Subject DID on the mobile app. Therefore verifying the JWS proves that the mobile app has access to the private key of the Subject DID.