---
title: "POST /script/{name}"
method: POST
path: "/script/{name}"
tags: ["Script"]
---

# POST /script/{name}

`POST /script/{name}`

Update an existing script or create a new one if it does not exist (in this case, the new script ID is returned in the data field).

## Path parameters

- `name` string, required

## Query parameters

- `text` string, required
- `insertOnly` boolean

## Response `200`

Success

- object
  - `status` string
  - `data` number

## Other responses

- `default` — Error

---

[API](https://skmtc.dev/phantombuster/apis/phantombuster-api-v2.md) · [All operations](https://skmtc.dev/phantombuster/apis/phantombuster-api-v2/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/phantombuster/phantombuster-api-v2/revisions/acf0049d7c7f/schema)
