Authenticate External Agents with an API Client
Security:
Security Administration
domain in the System functional area.To register external agents, you need an access token in your ASOR API invocation. Below are the different options to obtain a token to invoke the ASOR API call.
The user registering the agent must have access to the
Setup: Agents
domain in the Agent System of Record functional area to register an agent using the ASOR API.- Access theRegister API Clienttask.
- Complete the task:
Option Description Client NameEnter a unique identifiable name for your agent. We recommend that you use a separate client for each agent so that they are easier to manage.Client Grant TypeSelectAuthorization Code Grant.Access Token TypeSelectBearer.Redirection URIEnter a URL to redirect users to after authorization.Scope (Functional Areas)SelectAgent System of Record.Include Workday Owned ScopeSelect this check box. - Copy and save theClient IDandClient Secretvalues.You can use these to get an access token to call the Definition API.
- Paste this URL into a new window.You'll be redirected to google.com with an appended code you can use to call the API:https://us.agent.workday.com/auth/authorize/<Tenant_Name>?response_type=code&client_id=<client_id>&state=test3pagent1&redirect_uri=<redirect_uri>
- Create a new request using an external API Client.This generates an access token and refresh token that you can use to call the ASOR Agent Definition API. See External Agent ASU Considerations.
- Accesshttps://<tenantHost>/ccx/oauth2/<tenantName>/token
- Create the request:OptionDescriptionBodygrant_type=authorization_code&code=<authorizationCode>&client_id=<clientID>&client_secret=<ClientSecret>Username<ClientID>Password<ClientSecret>