Skip to main content

Enrolling a Client at a Wallet

The Authorization Server (AS) maintains a registry of approved service providers (https://AS_BASE_URL/registry/client). When the AS forwards authorization requests to the Wallet, it will include the client identifier included at this API (identifier). This key allows the Wallet to display the correct client information to the user.

Important

Although the Client is registered with specific request capabilities at the AS, this information is not currently duplicated at the Wallet. The Wallet trusts the AS will only forward valid Client Authorization Requests.

Request Attributes

ParameterDescriptionExample valueRequiredLocalizable
identifierAn identifier for the Enrolled ClientfpxspYesNo
spNameA human-readable name for the Enrolled ClientFPX Service ProviderYesYes
policyUriA URI to find information about client policyhttp://localhostYesYes
iconUriA URI to fetch an icon image for the Enrolled Clienthttp://localhostYesYes
tosUriA URI to find terms of service for the Enrolled Clienthttp://localhostYesYes
RelationshipDescriptionRequired
organizationThe organization to which this Enrolled Client belongs. See the example request above.Yes

Sample Requests

Enroll a Client

curl -X POST '{{WS_ADMIN_URI}}/authorization-server/1/enrolledClients' \
--header 'Content-Type: application/vnd.api+json' \
--header 'ApiVersion: v1.0' \
--header 'Authorization: {{WS_ADMIN_STATIC_TOKEN}}' \
--header 'Accept-Language: en' \
--data-raw '{
"data": {
"type": "enrolled-client",
"id": 1,
"attributes": {
"identifier": "fpxsp",
"spName": "FPX Service Provider",
"policyUri": "http://localhost",
"iconUri": "http://localhost",
"tosUri": "http://localhost"
},
"relationships": {
"organization": {
"data": {
"type": "organization",
"id": 1
}
}
}
}
}'

Get information about an Enrolled Client

curl -X POST '{{WS_ADMIN_URI}}/authorization-server/1/enrolledClients/1' \
--header 'Content-Type: application/vnd.api+json' \
--header 'ApiVersion: v1.0' \
--header 'Authorization: {{WS_ADMIN_STATIC_TOKEN}}' \
--header 'Accept-Language: en'

Update an Enrolled Client

curl -X PATCH '{{WS_ADMIN_URI}}/authorization-server/1/enrolledClients/1' \
--header 'Content-Type: application/vnd.api+json' \
--header 'ApiVersion: v1.0' \
--header 'Authorization: {{WS_ADMIN_STATIC_TOKEN}}' \
--header 'Accept-Language: en' \
--data-raw '{
"data": {
"type": "enrolled-client",
"id": 1,
"attributes": {
"identifier": "fpxsp2",
"spName": "FPX Service Provider2",
"policyUri": "http://localhost",
"iconUri": "http://localhost",
"tosUri": "http://localhost"
},
"relationships": {
"organization": {
"data": {
"type": "organization",
"id": 1
}
}
}
}
}'

Verify using the Wallet Application API: https://WALLET_BASE_URL/registry/clients

note

For details on how to add localization options for an Enrolled Client, refer to the Localization for the Wallet Server API chapter.