0

Delete Sent Update Request

by
Published Oct 17, 2025

Deletes the specified sent update request. **Delete operation is supported only when the specified sent update request is in the pending status. Deleting a sent update request that was already completed by recipient is not allowed.**

Script smartsheet Verified

The script

Submitted by hugo697 Bun
Verified 235 days ago
1
//native
2
type Smartsheet = {
3
  token: string;
4
  baseUrl: string;
5
};
6
/**
7
 * Delete Sent Update Request
8
 * Deletes the specified sent update request.
9

10
**Delete operation is supported only when the specified sent update request is in the pending status.
11
Deleting a sent update request that was already completed by recipient is not allowed.**
12

13
 */
14
export async function main(
15
  auth: Smartsheet,
16
  sheetId: string,
17
  sentUpdateRequestId: string,
18
) {
19
  const url = new URL(
20
    `${auth.baseUrl}/sheets/${sheetId}/sentupdaterequests/${sentUpdateRequestId}`,
21
  );
22

23
  const response = await fetch(url, {
24
    method: "DELETE",
25
    headers: {
26
      Authorization: "Bearer " + auth.token,
27
    },
28
    body: undefined,
29
  });
30
  if (!response.ok) {
31
    const text = await response.text();
32
    throw new Error(`${response.status} ${text}`);
33
  }
34
  return await response.json();
35
}
36