Package com.nimbusds.oauth2.sdk.client
Class ClientReadRequest
- java.lang.Object
-
- com.nimbusds.oauth2.sdk.AbstractRequest
-
- com.nimbusds.oauth2.sdk.ProtectedResourceRequest
-
- com.nimbusds.oauth2.sdk.client.ClientReadRequest
-
@Immutable public class ClientReadRequest extends ProtectedResourceRequest
Client read request.Example HTTP request:
GET /register/s6BhdRkqt3 HTTP/1.1 Accept: application/json Host: server.example.com Authorization: Bearer reg-23410913-abewfq.123483
Related specifications:
- OAuth 2.0 Dynamic Client Registration Management Protocol (RFC 7592), section 2.1.
- OAuth 2.0 Dynamic Client Registration Protocol (RFC 7591), section 2.
-
-
Constructor Summary
Constructors Constructor Description ClientReadRequest(URI uri, BearerAccessToken accessToken)
Creates a new client read request.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ClientReadRequest
parse(HTTPRequest httpRequest)
Parses a client read request from the specified HTTP GET request.HTTPRequest
toHTTPRequest()
Returns the matching HTTP request.-
Methods inherited from class com.nimbusds.oauth2.sdk.ProtectedResourceRequest
getAccessToken
-
Methods inherited from class com.nimbusds.oauth2.sdk.AbstractRequest
getEndpointURI
-
-
-
-
Constructor Detail
-
ClientReadRequest
public ClientReadRequest(URI uri, BearerAccessToken accessToken)
Creates a new client read request.- Parameters:
uri
- The URI of the client configuration endpoint. May benull
if thetoHTTPRequest()
method will not be used.accessToken
- An OAuth 2.0 Bearer access token for the request. Must not benull
.
-
-
Method Detail
-
toHTTPRequest
public HTTPRequest toHTTPRequest()
Description copied from interface:Request
Returns the matching HTTP request.- Returns:
- The HTTP request.
-
parse
public static ClientReadRequest parse(HTTPRequest httpRequest) throws ParseException
Parses a client read request from the specified HTTP GET request.- Parameters:
httpRequest
- The HTTP request. Must not benull
.- Returns:
- The client read request.
- Throws:
ParseException
- If the HTTP request couldn't be parsed to a client read request.
-
-