light-mode-image
Learn
MATTR VII PlatformClaim source

Update a claims source

Updates an existing claim source by providing its claimSourceID.

Analytic event

  • CLAIM_SOURCE_UPDATE_START
  • CLAIM_SOURCE_UPDATE_SUCCESS
  • CLAIM_SOURCE_UPDATE_FAIL

Roles

adminissuermanaged-issuer
PUT/v1/claim-sources/{id}

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Claims source ID

Formatuuid

Request Body

application/json

The updated claims source payload

name*string

Claims source name.

url*string

Claims source URL (and any redirects it may include):

  • Must be a valid URL.
  • Must use the HTTPS protocol.
  • Must not be an IP address.
  • Must not include query parameters.
  • Unicode will be converted to ASCII.
requestMethod?string

Indicates the request method MATTR VII will use when retrieving data from this claims source. Both the GET and POST method are supported. If no value is provided, GET is used by default. When using POST, all requestParameters must be included in the request body in JSON format.

Value in"GET" | "POST"
requestParameters*||

Use this object to define how to map request parameters that are sent to your claims source using the mapFrom and defaultValue properties:

  • When only providing mapFrom, the request parameter will be mapped from the defined path. If mapping fails, no alternative value is used. You can map data from both the claims and credentialConfiguration objects.
  • When providing both mapFrom and defaultValue, MATTR VII will attempt to map the request parameter from the defined path. If mapping fails, the defaultValue is used instead.
  • When only providing defaultValue, its value is used to populate the request parameter, regardless of any available claims values.
authorization*|

Authentication method configuration to access the claims source.

Response Body

application/json

application/json

application/json

curl -X PUT "https://example.vii.au01.mattr.global/v1/claim-sources/41458e5a-9092-40b7-9a26-d4eb43c5792f" \  -H "Content-Type: application/json" \  -d '{    "name": "My claims from example.com",    "url": "https://example.com",    "requestParameters": {      "mapFrom": "claims.accountType"    },    "authorization": {      "type": "api-key"    }  }'
{
  "id": "57fa09e2-82f3-4d3d-9eca-d0253e84a4e6",
  "name": "My claims from example.com",
  "url": "https://example.com",
  "requestMethod": "GET",
  "requestParameters": {
    "mapFrom": "claims.accountType"
  },
  "authorization": {
    "type": "api-key",
    "value": "****************************************61m1J"
  }
}
{
  "code": "BadRequest",
  "message": "Validation Error",
  "details": [
    {
      "location": "body",
      "msg": "Invalid value",
      "param": "url"
    }
  ]
}
{
  "code": "NotFound",
  "message": "Validation Error",
  "details": [
    {
      "location": "params",
      "msg": "Resource Not Found",
      "param": "claimSourceId",
      "value": "a368cfb4-9537-4439-acc6-ce3cf2287eb7"
    }
  ]
}

How would you rate this page?