-
Notifications
You must be signed in to change notification settings - Fork 47
/
verifier.yml
123 lines (123 loc) · 4.86 KB
/
verifier.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
openapi: 3.0.0
servers:
- url: https://verifier.qa.veres.app/verifiers/z1A45ZhWEGMeibHrB15nv8Gk6
description: Veres Issuer (Quality Assurance)
info:
version: "0.0.3-unstable"
title: VC Verifier API
description: This is an Experimental Open API Specification for the [VC Data Model](https://www.w3.org/TR/vc-data-model/).
license:
name: W3C Software and Document License
url: http://www.w3.org/Consortium/Legal/copyright-software.
contact:
name: GitHub Source Code
url: https://github.com/w3c-ccg/vc-api
paths:
/credentials/verify:
post:
summary: Verifies a verifiableCredential and returns a verificationResult in the response body.
tags:
- Credentials
security:
- networkAuth: []
- oAuth2: []
- zCap: []
operationId: verifyCredential
x-expectedCaller: "Verification Coordinator"
description: Verifies a verifiableCredential and returns a verificationResult in the response body.
requestBody:
content:
application/json:
schema:
$ref: "#/components/schemas/VerifyCredentialRequest"
description: Parameters for verifying a verifiableCredential.
responses:
"200":
description: Verifiable Credential successfully verified!
content:
application/json:
schema:
$ref: "#/components/schemas/VerifyCredentialResponse"
"400":
description: invalid input!
/presentations/verify:
post:
summary: Verifies a Presentation with or without proofs attached and returns a verificationResult in the response body.
tags:
- Presentations
security:
- networkAuth: []
- oAuth2: []
- zCap: []
operationId: verifyPresentation
x-expectedCaller: "Verification Coordinator"
description: Verifies a verifiablePresentation and returns a verificationResult in the response body. Given the possibility of denial of service, buffer overflow, or other style attacks, an implementation is permitted to rate limit or restrict requests against this API endpoint to those requests that contain only a single credential with a 413 or 429 error code as appropriate.
requestBody:
content:
application/json:
schema:
oneOf:
- $ref: "#/components/schemas/VerifyPresentationRequest"
- $ref: "#/components/schemas/ProoflessVerifyPresentationRequest"
description: Parameters for verifying a verifiablePresentation.
responses:
"200":
description: Verifiable Presentation successfully verified!
content:
application/json:
schema:
$ref: "#/components/schemas/VerifyPresentationResponse"
"400":
description: Invalid or malformed input
"413":
description: Payload too large
"429":
description: Request rate limit exceeded.
/challenges:
post:
summary: Passing an empty body to this endpoint creates and returns a challenge string in the response body.
security:
- networkAuth: []
- oAuth2: []
- zCap: []
operationId: challenge
x-expectedCaller: "Verification Coordinator"
description: Creates a challenge to be used as `options.challenge` in future requests.
responses:
"200":
description: Challenge created
content:
application/json:
schema:
$ref: "#/components/schemas/CreateChallengeResponse"
"400":
description: Invalid or malformed input
components:
securitySchemes:
$ref: "./components/SecuritySchemes.yml#/components/securitySchemes"
schemas:
VerifyCredentialRequest:
type: object
properties:
verifiableCredential:
$ref: "./components/VerifiableCredential.yml#/components/schemas/VerifiableCredential"
options:
$ref: "./components/VerifyCredentialOptions.yml#/components/schemas/VerifyCredentialOptions"
VerifyCredentialResponse:
$ref: "./components/VerifyCredentialResult.yml#/components/schemas/VerificationResult"
VerifyPresentationRequest:
type: object
properties:
verifiablePresentation:
$ref: "./components/VerifiablePresentation.yml#/components/schemas/VerifiablePresentation"
options:
$ref: "./components/VerifyPresentationOptions.yml#/components/schemas/VerifyPresentationOptions"
ProoflessVerifyPresentationRequest:
type: object
properties:
presentation:
$ref: "./components/Presentation.yml#/components/schemas/Presentation"
VerifyPresentationResponse:
$ref: "./components/VerifyPresentationResult.yml#/components/schemas/VerificationResult"
CreateChallengeResponse:
$ref: "./components/Challenge.yml#/components/schemas/CreateChallengeResult"