Skip to main content
GET
/
agents
/
{agent_id}
/
workflow
/
code
python
from notte_sdk import NotteClient

notte = NotteClient()

agent = notte.Agent(agent_id="<agent_id>")
print(agent.workflow.code())
{
  "python_script": "<string>",
  "json_actions": [
    {}
  ]
}

Authorizations

Authorization
string
header
required

The access token received from the authorization server in the OAuth 2.0 flow.

Headers

x-notte-request-origin
string | null
x-notte-sdk-version
string | null

Path Parameters

agent_id
string
required

Query Parameters

as_workflow
boolean
required

Whether to return code as standalone workflow or just relevant instructions

Response

Successful Response

python_script
string
required

Python script to replicate agent steps

json_actions
Json Actions · object[]
required

Json actions to replicate agent steps