Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lobot/ad968709547f618f330586a1166c8783 to your computer and use it in GitHub Desktop.
Save lobot/ad968709547f618f330586a1166c8783 to your computer and use it in GitHub Desktop.
help-center-mass-delete-cancel-typescript
const config: Configuration = new Configuration({
username: "test_XXXXXXXXX",
});
const postcardsApi = new PostcardsApi(config);
const listOfPostcards = await postcardsApi.list(
undefined,
undefined,
undefined,
undefined,
undefined,
{ batch_id: "NEWYORK2022" }
);
for (let postcard of listOfPostcards) {
await postcardsApi.cancel(postcard.id);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment