Example flow for external users
The following diagrams identify the flow of authentication and authorization information for external users. Colors are used in the following ways:
- Orange - credentials information
- Blue - endpoint access information
- Green - resource access information
- Red - proxy user and session user information
Some values are used to determine multiple types of access. These values initially appear as black (when they do not apply to a single type of access), and then later appear in one or more specific colors (to reflect the value is being used at that point in the process for a specific type of access).
External contact authorization ID example
In the following example, an API call is triggered by Ray Newton, who is an external user, using a browser-based application.

- When Ray triggers an API call, the caller application must first request a JWT from
Guidewire Hub. To initiate the process of getting the JWT, the caller application submits
its client ID (
00ubx7m33sHP1tsew7b4), the ID of the IdP (acmeIdP_ID), the application's resource access strategy (bc_contactAuthorizationIds), and additional deployment information (tenant.acme,project.default,planet_class.prod). - Guidewire Hub sends a request to the appropriate IdP to authenticate the user. The IdP
authenticates the user and provides a SAML response with information about the user, such as
the user's name (
rnewton@email.com). If API roles and/or resource access IDs are stored in the IdP, the SAML response may also include this information (such as the rolegwa.prod.bc.Account_Contactor the resource access IDctc-11450). - Guidewire Hub sends a code to the caller application. The caller application uses this code to request a JWT.
- Guidewire Hub generates a JWT and sends it to the caller application. This JWT includes
the client ID (
cid), ascptoken claim which names the resource access strategy (bc_contactAuthorizationIds) and additional deployment information. The JWT also contains any relevant information Guidewire Hub received in the SAML response, such as agroupstoken which names the user's API roles (gwa.prod.bc.Account_Contact), or abc_contactAuthorizationIdstoken which names the user's resource access IDs (ctc-11450). - The caller application sends the API request to BillingCenter along with the JWT.
- BillingCenter extracts the information in the JWT into a token map. Then, the IExpandTokenPlugin plugin calls any relevant authorization applications to retrieve any relevant additional auth values that must be added to or modified in the token map. (For external users, this could include API roles and/or resource access IDs that are not stored in the IdP.)
- BillingCenter determines the endpoint access. Based on the
groups listed in the token map (
gwa.prod.bc.Account_Contact), theAccount_Contact.role.yamlAPI role file is used to define the endpoint access. - Next, BillingCenter determines the resource access strategy.
Based on the resource access strategy value in the token map
(
bc_contactAuthorizationIds), it grants resource access as defined in thecontactAuthorizationIdsaccess.yamlfiles. (* BillingCenter starts withcontactAuthorizationIds_ext-1.0.access.yaml, but this file references additionalaccess.yamlfiles whose name starts with "contactAuthorizationIds".) - To determine which proxy user to assign to the session, BillingCenter calls the
RestAuthenticationSourceCreatorplugin. The token map specified a resource access strategy ofbc_contactAuthorizationIds. So, the plugin returns the proxy user for external users:extuser. - BillingCenter processes the request.
- The session user is the proxy external user:
extuser. - The endpoint access is defined by
Account_Contact.role.yaml. - The resource access is defined by
contactAuthorizationIdsaccess.yamlusing the resource access ID ofctc-11450.
- The session user is the proxy external user:
- BillingCenter provides the response to the initial call.
External producer example
In the following example, an API call is triggered by Karen Egerston, who is a producer and external user, using a browser-based web application.

- When Karen triggers an API call, the caller application must first request a JWT from
Guidewire Hub. To initiate the process of getting the JWT, the caller application submits
its client ID (
00ubx7m33sHP1tsew7b4), the ID of the IdP (acmeIdP_ID), the application's resource access strategy (bc_producerCodes), and additional deployment information (tenant.acme,project.default,planet_class.prod). - Guidewire Hub sends a request to the appropriate IdP to authenticate the user. The IdP
authenticates the user and provides a SAML response with information about the user, such
as the user's name (
kegerston@email.com). The SAML response includes information about the resource access strategy (gwa.prod.bc.Producer_Code) and the resource access IDs (ProducerCodeABCandProducerCodeDEF). - Guidewire Hub sends a code to the caller application. The caller application uses this code to request a JWT.
- Guidewire Hub generates a JWT and sends it to the caller application. This JWT includes
the client ID (
cid), ascptoken claim which names the resource access strategy (bc_producerCodes) and additional deployment information. The JWT also contains any relevant information Guidewire Hub received in the SAML response, such as agroupstoken which names the user's API roles (gwa.prod.bc.Producer_Code), or abc_producerCodestoken which names the user's resource access IDs (ProducerCodeABCandProducerCodeDEF). - The caller application sends the API request to BillingCenter along with the JWT.
- BillingCenter extracts the information in the JWT into a token map. Then, the IExpandTokenPlugin plugin calls any relevant authorization applications to retrieve any relevant additional auth values that must be added to or modified in the token map. (For external users, this could include API roles and/or resource access IDs that are not stored in the IdP.)
- BillingCenter determines the endpoint access. Based on the
groups listed in the token map (
gwa.prod.bc.Producer_Code), theProducer_Code.role.yamlAPI role file is used to define the endpoint access. - Next, BillingCenter determines the resource access
strategy. Based on the resource access strategy value in the token map
(
bc_producerCodes), it grants resource access as defined in theproducerCodesaccess.yamlfiles. (* BillingCenter starts withproducerCodes_ext-1.0.access.yaml, but this file references additionalaccess.yamlfiles whose name starts with "producerCodes".) - To determine which proxy user to assign to the session, BillingCenter calls the
RestAuthenticationSourceCreatorplugin. The token map specified a resource access strategy ofbc_producerCodes. So, the plugin returns the proxy user for external users:externalProducerCodeUser. - BillingCenter processes the request.
- The session user is the proxy external user:
externalProducerCodeUser. - The endpoint access is defined by
Producer_Code.role.yaml. - The resource access is defined by
producerCodesaccess.yamlusing an array of resource access ids with two items:ProducerCodeABCandProducerCodeDEF.
- The session user is the proxy external user:
- BillingCenter provides the response to the initial call.