Pro-code agents

You can use third-party agent SDKs in Code Repositories to build agents backed by a large language model (LLM). A pro-code agent is custom logic written in a Foundry code repository and published as a Foundry function. The agent can reason over a prompt and call tools that read and write data in your environment. Supported third-party agent SDKs include the Claude Agent SDK, OpenAI Agents SDK, and Google ADK.

Pro-code agents can accomplish tasks such as reading and writing Ontology data, building platform resources, and migrating legacy systems. For more ways to use pro-code agents, see the use cases documentation.

Pro-code agents authenticate against the Ontology SDK (OSDK), Ontology MCP (OMCP), and Palantir MCP with scoped permissions out of the box. You do not need to pass a client ID and secret to call tools. After you publish a pro-code agent, you can call it from Workshop or the Ontology SDK without any additional configuration.

How pro-code agents work

A pro-code agent is defined in a code repository created from an agent template. The template includes:

  1. An OSDK client bound to your selected Ontology, used to read and write Ontology data.
  2. Ontology MCP and Palantir MCP configuration, exposing Ontology resources and platform tools to the agent's LLM.
  3. The agent's logic, where you define the prompt, the tools the agent can call, and how the agent consumes the model's response stream.

When you publish the agent, Foundry registers it with an Ontology binding and an agent API name. The published agent is exposed as an asynchronous function. We recommend triggering agents from Automate, but you can also call them from Workshop, the Ontology SDK, and Ontology actions.

Key capabilities

  • Scoped permissions out of the box: Pro-code agents authenticate against OSDK, OMCP, and Palantir MCP with scoped permissions automatically. You do not wire up client credentials manually to use tools.
  • Templates for the Claude Agent SDK, OpenAI Agents SDK, and Google ADK: Create your pro-code agent from a template for the Claude Agent SDK ↗, OpenAI Agents SDK ↗, or Google Agent Development Kit (ADK) ↗. Each template ships with simplified configuration for OMCP, Palantir MCP, and the OSDK client, with common setup provided by the agent library.
  • Published with an Ontology binding and agent API name: Every pro-code agent is published with an Ontology binding and an agent API name, making its function callable from both Workshop and OSDK.
  • Guided walkthrough: After you create a pro-code agent, a Build agents in Foundry landing page walks you through the next steps of building, publishing, and calling your agent.
  • Build your agent with Continue: Use Palantir MCP with Continue ↗ to manage both the SDK and the OMCP scope attached to the pro-code agent, directly from your editor.

Next steps