---
title: "Create Web3 Action"
method: POST
path: "/v1/account/{accountSlug}/project/{projectSlug}/actions/publishFile"
tags: ["Actions"]
---

# Create Web3 Action

`POST /v1/account/{accountSlug}/project/{projectSlug}/actions/publishFile`

Create a new Web3 Action. You can also set the Web3 Action to be deployed once it's been created.

## Path parameters

- `accountSlug` string, required
- `projectSlug` string, required

## Request body

- CreateWeb3ActionPayload
  - `action` Web3ActionPayload, required — A Web3 Action creation payload.
    - `name` string, required — Web3 Action name.
    - `description` string — Web3 Action description.
    - `source` string, required — Web3 Action version source code.
    - `triggerType` 'ALERT' | 'BLOCK' | 'PERIODIC' | 'TRANSACTION' | 'WEBHOOK' | 'TRANSACTIONSIMPLE', required — Web3 Action version trigger type.
    - `runtime` string, required — Web3 Action version runtime.
    - `function` string, required — Web3 Action function which will be called on every execution.
    - `invocationType` 'SYNC' | 'ASYNC', required — Shows Web3 Action version invocation type.
    - `trigger` object, required — Web3 Action version trigger object.
  - `deploy` boolean, required — Should Web3 Action be immediately deployed.

## Response `200`

A successful response.

- union
  - BlockCreateWeb3ActionPostResponse — An object with details about created Web3 Action of Block type.
  - PeriodicCreateWeb3ActionPostResponse — An object with details about created Web3 Action of Periodic type.
  - WebhookCreateWeb3ActionPostResponse — An object with details about created Web3 Action of Webhook type.

## Other responses

- `400` — Bad Request
- `401` — Unauthorized
- `403` — Forbidden
- `404` — The resource was not found.
- `429` — The request was rate limited. See the [rate limits](#section/Introduction/Rate-limits) section for the current limits and how request counts expire.
- `500` — Server error.

---

[API](https://skmtc.net/tenderly/apis/tenderly-api.md) · [All operations](https://skmtc.net/tenderly/apis/tenderly-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/tenderly/tenderly-api/versions/59b67cf882bc/schema)
