ForkbombEu / DIDroom_microservices

DIDroom credential issuer part of Forkbomb's SSI solution
1 stars 0 forks source link

Error handling /par #20

Open puria opened 8 months ago

puria commented 8 months ago

As per https://datatracker.ietf.org/doc/html/rfc9126.html#section-2.3

The response MUST use application/json as the content type and MUST include the following parameters:

errors example format:

 HTTP/1.1 400 Bad Request
 Content-Type: application/json
 Cache-Control: no-cache, no-store

 {
   "error": "invalid_request",
   "error_description":
     "The redirect_uri is not valid for the given client"
 }

also e authorization server MUST only accept requests complying with the definition given in Section 3 and MUST refuse any other request with HTTP status code 400 and error code invalid_request.In addition to the above, the PAR endpoint can also make use of the following HTTP status codes:

405: If the request did not use the POST method, the authorization server responds with an HTTP 405 (Method Not Allowed) status code.

413: If the request size was beyond the upper bound that the authorization server allows, the authorization server responds with an HTTP 413 (Payload Too Large) status code. 429: If the number of requests from a client during a particular time period exceeds the number the authorization server allows, the authorization server responds with an HTTP 429 (Too Many Requests) status code.

puria commented 1 month ago

This is actually true for all the calls, not just /par ;(