Connectors

/

ServiceNow

/

Close a ServiceNow change request
Write

Close ServiceNow changes only when the work is really done

For change managers who want ServiceNow changes closed with an honest code, after open tasks and linked outages are checked, by asking their AI assistant.

Try PopdockAI free
Get a live demo
Close a ServiceNow change request
Close CHG0031245 in ServiceNow as successful. Notes: deployed to all three app servers, smoke tests passed.
CHG0031245 is in review with all 3 tasks closed and no linked outage, so it can close. - State: Review to Closed - Close code: Successful - Notes: Deployed to all three app servers, smoke tests passed Shall I close it?
ServiceNow
Sample figures. Your results come from your own account.
servicenow-get-change-request
servicenow-get-change-task
servicenow-get-outages-task-link
servicenow-update-change-request

On this page

The problem

The problem

The prompt

Who it's for

How it works

Tools used

Connector

ServiceNow

ServiceNow
Run it on your own ServiceNow data.

Connect ServiceNow, pick your AI tool and paste the prompt.

Try PopdockAI free

The problem

Changes closed as successful with open tasks and outages

A ServiceNow change should close only once its tasks are done and its outcome is honest. In practice changes get closed with tasks still open, or marked successful even though an outage was linked to them.

Without PopdockAI

  • Close the change from the form
  • Skip checking its change tasks
  • Miss a linked outage
  • Record a success that was not one

With PopdockAI

  • Already closed changes and open tasks stop the job
  • A linked outage blocks a successful close until you confirm the code
  • You see exactly what will be set before anything changes
  • The change is re-read to show its new state

The prompt

Use this prompt

Copy it into any AI tool connected to PopdockAI. Swap the values in braces for your own.

Prompt
**Objective:** Close change `{change-number}` with close code `{close-code}` and notes `{close-notes}`.

**Step 1: Read the change and its tasks**

* Call `servicenow-get-change-request` with number `{change-number}`. Keep sys-id and state. If Closed or Canceled, stop.
* Call `servicenow-get-change-task` with change-request `{change-number}`.

**Step 2: Gate**

* If any change task is still open, list them and stop. Tasks must be finished first.
* Call `servicenow-get-outages-task-link` with task `{change-number}`. A linked outage means the close code cannot be Successful: tell the user and ask them to confirm the code.
* If the state is not Review or Implement, warn that the change may not have been implemented.

**Step 3: Confirm**

Show: change number, short-description, current state, new state Closed, close code `{close-code}` and the notes. Ask for an explicit yes.

**Step 4: Write once**

Call `servicenow-update-change-request` once with sys-id, state Closed, close-code `{close-code}` and close-notes `{close-notes}`.

**Step 5: Verify**

Re-read with `servicenow-get-change-request` and report the new state. If `{close-code}` is Unsuccessful, suggest raising a problem.

**Rules & Guidelines:**

* The only write tool this prompt may call is `servicenow-update-change-request`, once, after confirmation. Do not close open tasks on the user's behalf with `servicenow-update-change-task`.

**Validation:**

* If `{change-number}` is not found, stop. If the update is rejected, report the error verbatim.

Who it's for

One answer, three teams that use it

Change implementers

Close your change straight after the work

Record the outcome and notes in one message, with open tasks caught first.

Close CHG0045120 as successful. Notes: patch applied to both nodes, monitoring green.

Change managers

Keep change outcomes honest

A linked outage stops a change being closed as successful without a second look.

Close CHG0045188 as unsuccessful, rollback completed after database errors.

Problem managers

Catch failed changes worth investigating

An unsuccessful close prompts a suggestion to raise a problem.

Close CHG0045201 as successful with issues: two app servers needed a manual restart.

How it works

What PopdockAI does when you ask

You give the change number, close code and notes, and your AI assistant checks the change is really ready to close. It updates the change only after you confirm.

01

Ask

You give the change number, close code and notes.

Your AI tool

02

Check

It stops on open tasks and questions a successful code if an outage is linked.

servicenow-get-change-request
servicenow-get-change-task
servicenow-get-outages-task-link

03

Confirm

You see exactly what will be set and say yes.

No items found.

04

Close

It updates the change once and re-reads it to show the new state.

Your AI tool

What PopdockAI provides

The tools behind the answer

Ready made tools for ServiceNow and one secure connection to your AI tool. No code, no exports.

get-data

servicenow-get-change-request

Returns change request records (type, state, risk, approval and planned window) from ServiceNow. Filter by number, type, state, risk, assignment group, assignee, short description text and planned start date range.
get-data

servicenow-get-change-task

Returns change task records, with the change request each belongs to, from ServiceNow. Filter by number, change request, type, state, assignment group, assignee, short description text and planned start date range.
get-data

servicenow-get-outages-task-link

Returns links between tasks and the outages they caused or relate to from ServiceNow. Filter by task or outage text.
run-action

servicenow-update-change-request

Updates an existing change request record in ServiceNow (the change_request table), identified by its sys_id. Only the fields you pass are changed.
Read only.Nothing in ServiceNow Changes

This report is built from Get data tools only. PopdockAI applies the row, field and parameter rules your admin sets, and every query is written to the audit trail.

How Popdock AI secures your data

The outcome

Changes close truthfully, when the work is done

Try PopdockAI free
Get a live demo

Related use cases

More ways to put this data to work

All Ramp use cases

One prompt template with infinite possibilities.

‍

Your AI assistant adapts its approach, tone, and capabilities to match each unique context while you maintain a single, manageable workflow.

Join forward-thinking companies that are transforming their operations with intelligent, secure AI automation.

Try PopdockAI Free
See Documentation