Skip to content

Add Functions API documentation for the commit flow#380

Open
c1-dev-bot[bot] wants to merge 1 commit into
mainfrom
docs/fn-524
Open

Add Functions API documentation for the commit flow#380
c1-dev-bot[bot] wants to merge 1 commit into
mainfrom
docs/fn-524

Conversation

@c1-dev-bot

@c1-dev-bot c1-dev-bot Bot commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

Summary

Add a new documentation page (product/admin/functions-api.mdx) that documents how to manage functions programmatically via the C1 REST API.

The existing Functions docs cover only the web UI workflow. This page documents:

  • The three-step commit flow for editing function code via API: CreateInitialCommit (to get signed upload URLs) → upload files to the signed URLs → CreateFinalCommit
  • Creating functions with optional inline initialContent
  • Publishing commits by updating publishedCommitId
  • A complete bash example showing the full create-upload-finalize-publish sequence
  • Other operations: list/get/delete functions, invoke, test, list commits, get commit content

Why

The API reference (auto-generated from the OpenAPI spec) advertises a content field on the commit endpoint that the server does not accept (HTTP 400). Without documentation of the working three-step flow, API users are forced to delete and recreate functions to update code — which generates new function IDs and breaks bound hooks, vault secrets, egress allowlists, and saved references.

Fixes: FN-524


Automated PR Notice

This PR was automatically created by c1-dev-bot as a potential implementation.

This code requires:

  • Human review of the implementation approach
  • Manual testing to verify correctness
  • Approval from the appropriate team before merging

Document the working three-step commit flow for editing function code
via the REST API (CreateInitialCommit -> upload -> CreateFinalCommit),
which is currently undocumented. Also covers creating, publishing,
listing, deleting, invoking, and testing functions via API.
@linear-code

linear-code Bot commented Jul 7, 2026

Copy link
Copy Markdown

FN-524

@mintlify

mintlify Bot commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated (UTC)
conductorone 🟢 Ready View Preview Jul 7, 2026, 5:17 AM

💡 Tip: Enable Workflows to automatically generate PRs for you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant