Get change request state

1 minute read

Use this functionality to obtain the current state of the change request. The user must provide valid credentials (Basic authentication or OAuth authentication) and the change request ticket number.

The action input must include the cr-number attribute.
All CloudBees action repositories are listed at CloudBees, Inc. on GitHub.

Input fields

The following table lists the fields for get change request:

Table 1. Fields for GET change request
Change request model field Data type Required Description

action-type

String

Yes

The type of operation is get.

url

String

Yes

The ServiceNow host URL.

username

String

Yes

The username for authentication. This is required for basic authentication and OAuth authentication.

password

String

Yes

The password for authentication. This is required for basic authentication and OAuth authentication.

client-id

String

Required only for OAuth based authentication.

The unique identification number of the client.

client-secret

String

Required only for OAuth based authentication.

The client secret for authentication.

cr-number

String

Yes

The unique number auto-generated during change request creation.

Usage example

The following is an example change request payload with mandatory fields for the get change request:

- name: Servicenow Action with Basic Auth uses: cloudbees-io/service-now@v1 with: url: ${{ vars.SERVICENOW_URL }} username: "username" password: "password" action-type: "get" cr-number: "CR ticket number"