openapi: 3.2.0 info: title: Phi — Protein Design Agents API description: 'Phi is a biomodal computation platform for protein design. Submit structure-prediction and sequence-design jobs, track their status, and retrieve scored results — all via a single REST API. ## Authentication All endpoints require an API key supplied as `Authorization: Bearer ` or a Clerk session token. Organisation ID is derived automatically from Clerk tokens; static-key callers must include `X-Organization-ID`. ## Quick links - `POST /v1/phi/jobs` — submit a job - `GET /v1/phi/jobs/{job_id}/status` — poll status - `GET /v1/phi/jobs/{job_id}/scores` — download scored results ' version: 1.0.0 servers: - url: https://api.dyno-agents.app description: Production - url: http://localhost:8000 description: Local development tags: - name: agents paths: /v1/phi/agents/: post: tags: - agents summary: Create Agent description: Create new agent. operationId: create_agent_v1_phi_agents__post parameters: - name: x-api-key in: header required: false schema: anyOf: - type: string - type: 'null' description: API key for authentication title: X-Api-Key description: API key for authentication - name: X-User-ID in: header required: false schema: anyOf: - type: string - type: 'null' title: X-User-Id - name: X-Organization-ID in: header required: false schema: anyOf: - type: string - type: 'null' title: X-Organization-Id requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/CreateAgentRequest' responses: '200': description: Successful Response content: application/json: schema: type: object additionalProperties: true title: Response Create Agent V1 Phi Agents Post '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' get: tags: - agents summary: List Agents description: List agents for organization. operationId: list_agents_v1_phi_agents__get parameters: - name: status in: query required: false schema: anyOf: - type: string - type: 'null' title: Status - name: limit in: query required: false schema: type: integer default: 100 title: Limit - name: offset in: query required: false schema: type: integer default: 0 title: Offset - name: x-api-key in: header required: false schema: anyOf: - type: string - type: 'null' description: API key for authentication title: X-Api-Key description: API key for authentication - name: X-User-ID in: header required: false schema: anyOf: - type: string - type: 'null' title: X-User-Id - name: X-Organization-ID in: header required: false schema: anyOf: - type: string - type: 'null' title: X-Organization-Id responses: '200': description: Successful Response content: application/json: schema: type: object additionalProperties: true title: Response List Agents V1 Phi Agents Get '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v1/phi/agents/{agent_id}: get: tags: - agents summary: Get Agent description: Get agent by ID. operationId: get_agent_v1_phi_agents__agent_id__get parameters: - name: agent_id in: path required: true schema: type: string title: Agent Id - name: x-api-key in: header required: false schema: anyOf: - type: string - type: 'null' description: API key for authentication title: X-Api-Key description: API key for authentication - name: X-User-ID in: header required: false schema: anyOf: - type: string - type: 'null' title: X-User-Id - name: X-Organization-ID in: header required: false schema: anyOf: - type: string - type: 'null' title: X-Organization-Id responses: '200': description: Successful Response content: application/json: schema: type: object additionalProperties: true title: Response Get Agent V1 Phi Agents Agent Id Get '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' put: tags: - agents summary: Update Agent description: Update agent configuration and/or tools. operationId: update_agent_v1_phi_agents__agent_id__put parameters: - name: agent_id in: path required: true schema: type: string title: Agent Id - name: x-api-key in: header required: false schema: anyOf: - type: string - type: 'null' description: API key for authentication title: X-Api-Key description: API key for authentication - name: X-User-ID in: header required: false schema: anyOf: - type: string - type: 'null' title: X-User-Id - name: X-Organization-ID in: header required: false schema: anyOf: - type: string - type: 'null' title: X-Organization-Id requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/UpdateAgentRequest' responses: '200': description: Successful Response content: application/json: schema: type: object additionalProperties: true title: Response Update Agent V1 Phi Agents Agent Id Put '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v1/phi/agents/{agent_id}/tools: post: tags: - agents summary: Update Agent Tools description: Update which tools are enabled for agent. operationId: update_agent_tools_v1_phi_agents__agent_id__tools_post parameters: - name: agent_id in: path required: true schema: type: string title: Agent Id - name: x-api-key in: header required: false schema: anyOf: - type: string - type: 'null' description: API key for authentication title: X-Api-Key description: API key for authentication - name: X-User-ID in: header required: false schema: anyOf: - type: string - type: 'null' title: X-User-Id - name: X-Organization-ID in: header required: false schema: anyOf: - type: string - type: 'null' title: X-Organization-Id requestBody: required: true content: application/json: schema: type: array items: type: string title: Tool Ids responses: '200': description: Successful Response content: application/json: schema: type: object additionalProperties: true title: Response Update Agent Tools V1 Phi Agents Agent Id Tools Post '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' components: schemas: HTTPValidationError: properties: detail: items: $ref: '#/components/schemas/ValidationError' type: array title: Detail type: object title: HTTPValidationError UpdateAgentRequest: properties: config: anyOf: - $ref: '#/components/schemas/AgentConfig' - type: 'null' description: Updated agent configuration tool_ids: anyOf: - items: type: string type: array - type: 'null' title: Tool Ids description: Updated tool IDs type: object title: UpdateAgentRequest description: Request to update agent. ValidationError: properties: loc: items: anyOf: - type: string - type: integer type: array title: Location msg: type: string title: Message type: type: string title: Error Type type: object required: - loc - msg - type title: ValidationError AgentConfig: properties: name: type: string title: Name description: Agent name (e.g., 'proteinmpnn-designer') instructions: type: string title: Instructions description: System prompt/instructions for the agent. Should be general-purpose, not prescriptive. model: type: string title: Model description: LLM model to use default: gpt-4o temperature: type: number title: Temperature description: Temperature for LLM responses default: 0.1 tool_choice: anyOf: - type: string - type: 'null' title: Tool Choice description: 'Tool choice strategy: ''auto'', ''required'', ''none'', or None for default behavior' tools: items: {} type: array title: Tools description: List of FunctionTools this agent can use type: object required: - name - instructions title: AgentConfig description: Configuration for an AI agent. CreateAgentRequest: properties: config: $ref: '#/components/schemas/AgentConfig' description: Agent configuration name: type: string title: Name description: Agent name description: anyOf: - type: string - type: 'null' title: Description description: Optional description tool_ids: items: type: string type: array title: Tool Ids description: Enabled tool IDs type: object required: - config - name title: CreateAgentRequest description: Request to create agent.