---
title: "List all available code mode functions from both server and tool registrations"
method: POST
path: "/code-mode/functions/list"
tags: ["CodeMode"]
---

# List all available code mode functions from both server and tool registrations

`POST /code-mode/functions/list`

## Headers

- `x-code-mode-session` string, required

## Response `200`

List of all code mode functions as source code & structured output

- ListFunctionsOutput
  - `code` string, required
  - `functions` ListedFunction[], required — Available functions
    - `description` string, nullable — Function description
    - `name` string, required — Function name
    - `namespace` string, required — Namespace the function belongs in

## Other responses

- `500` — Internal server error

---

[API](https://skmtc.dev/portofcontext/apis/pctx-agent-server-api.md) · [All operations](https://skmtc.dev/portofcontext/apis/pctx-agent-server-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/portofcontext/pctx-agent-server-api/revisions/d1f357cea012/schema)
