curl 'https://api.tenderly.co/api/v2/account/${TENDERLY_ACCOUNT_SLUG}/project/${TENDERLY_PROJECT_SLUG}/simulation-drafts/3f2a6c1e-8f1b-4c8e-9a2d-6b1e0f7c4d21' \
-H 'X-Access-Key: ${TENDERLY_ACCESS_KEY}' \
--compressedconst options = {method: 'GET', headers: {'X-Access-Key': '<api-key>'}};
fetch('https://api.tenderly.co/api/v2/account/{accountSlug}/project/{projectSlug}/simulation-drafts/{draftId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.tenderly.co/api/v2/account/{accountSlug}/project/{projectSlug}/simulation-drafts/{draftId}"
headers = {"X-Access-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.tenderly.co/api/v2/account/{accountSlug}/project/{projectSlug}/simulation-drafts/{draftId}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Access-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}Get a simulation draft
Fetch a stored simulation draft by ID. The account and project in the URL are the caller’s own (any project the caller can view); the draft’s visibility determines access:
- A project-scoped draft returns
payloadtogether with the originaccount_idandproject_idwhen the caller can view the draft’s origin project. - A shared draft returns
payloadonly, with no origin information. - An unknown ID, an expired draft, and a project-scoped draft the caller cannot access all return the same
404, so draft IDs cannot be probed.
Learn more about Simulator draft links, including how to obtain a payload for an advanced setup from a draft created in the dashboard.
curl 'https://api.tenderly.co/api/v2/account/${TENDERLY_ACCOUNT_SLUG}/project/${TENDERLY_PROJECT_SLUG}/simulation-drafts/3f2a6c1e-8f1b-4c8e-9a2d-6b1e0f7c4d21' \
-H 'X-Access-Key: ${TENDERLY_ACCESS_KEY}' \
--compressedconst options = {method: 'GET', headers: {'X-Access-Key': '<api-key>'}};
fetch('https://api.tenderly.co/api/v2/account/{accountSlug}/project/{projectSlug}/simulation-drafts/{draftId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.tenderly.co/api/v2/account/{accountSlug}/project/{projectSlug}/simulation-drafts/{draftId}"
headers = {"X-Access-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.tenderly.co/api/v2/account/{accountSlug}/project/{projectSlug}/simulation-drafts/{draftId}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Access-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}Authorizations
An API key is a token that a client provides when making API calls. Send it as the X-Access-Key request header on any endpoint:
curl '<API_ENDPOINT>' \ -H 'X-Access-Key: ${TENDERLY_ACCESS_KEY}' \ ...
Learn how to generate API access tokens at Tenderly Docs.
Path Parameters
Account slug of the user
Project slug of the account
ID of the simulation draft (the resource_id returned on creation, and the draftId in a dashboard draft link)
Response
The stored draft.
A Simulator form snapshot. The API stores it as received; the dashboard validates it when the draft opens. A wrong v, an empty rows array, a non-string contractAddress, or a wrong-typed row field rejects the whole draft on open.
Show child attributes
Show child attributes
ID of the account that owns the project the draft was created in. Present only for project-scoped drafts, when the caller can view that project. Absent for shared drafts.
"fa4a29af-ad72-44ac-9261-4bf3a8af3a06"
ID of the project the draft was created in. Present only for project-scoped drafts, when the caller can view that project. Absent for shared drafts.
"aaf3c9e1-9632-4e6e-a900-b704db935f74"