Authentication

Obtain OAuth2 Token (client_credentials)

Obtain an access token using the OAuth2 client_credentials grant. Send your client_id and client_secret. Returns an RS256-signed JWT; the scope claim is a space-separated list of ACLs and no refresh token is returned.

Requires the x-api-key header on this request itself, not just on the downstream FHIR calls that follow. Omitting it still returns a 200 with a valid-looking token, but every downstream FHIR call then fails. This is the x-api-key provisioned for your client_credentials vendor application — a different value than the one used with the legacy password grant.

post/auth/realms/ema-fhir/protocol/openid-connect/token

Request

  • Base URL
    https://ssoqa01-lb-01.m2qa.com
  • URL
    https://ssoqa01-lb-01.m2qa.com/auth/realms/ema-fhir/protocol/openid-connect/token
  • Auth
    API key in header x-api-key

Request body application/x-www-form-urlencoded

grant_typestring required
client_idstring required

Your vendor application's client_id

client_secretstring required

Your vendor application's client_secret

Response

Access token response

access_tokenstring

RS256-signed JWT

expires_ininteger
refresh_expires_ininteger
token_typestring
not-before-policyinteger
scopestring

Space-separated list of ACL scopes

Example response

{
  "expires_in": 900,
  "token_type": "Bearer",
  "scope": "acl/enc_s acl/pat_s_name_dob_gen"
}

Changes

No recorded changes to this operation across all 2 revisions of this API.