Skip to content

Add POST /companies/{id}/notes endpoint to OpenAPI spec (Unstable)#374

Open
efassor wants to merge 2 commits intomainfrom
add-company-notes-post-endpoint
Open

Add POST /companies/{id}/notes endpoint to OpenAPI spec (Unstable)#374
efassor wants to merge 2 commits intomainfrom
add-company-notes-post-endpoint

Conversation

@efassor
Copy link

@efassor efassor commented Feb 20, 2026

Why?

PR #470943 added the ability to create notes on company records via the API, but the OpenAPI specification wasn't updated. Developers need the OpenAPI documentation to discover and use this new endpoint, and downstream tools/SDKs rely on the spec for code generation.

How?

Added the POST endpoint to the Unstable version (descriptions/0/api.intercom.io.yaml) following the same pattern as the existing POST /contacts/{id}/notes endpoint, with company-specific adaptations (UUID string IDs instead of integer IDs).

Implementation Details

Endpoint: POST /companies/{id}/notes
Operation ID: createCompanyNote
Tags: Notes, Companies

Key differences from contact notes:

  • Company IDs are type: string (UUIDs) vs contact IDs which are type: integer
  • Request body uses company_id instead of contact_id
  • Response includes company object instead of contact object
  • Error messages reference "Company Not Found"

Request Body:

  • body (string, required): The note text
  • company_id (string): Company UUID
  • admin_id (string): Admin ID (defaults to token owner if not provided)

Responses:

  • 200: Returns note object with company reference
  • 404: Company not found or admin not found

OAuth Scope: post_companies_list

Generated with Claude Code

efassor and others added 2 commits February 20, 2026 12:17
### Why?

The implementation in PR #470943 adds the ability to create notes on company records
via the API, but requires corresponding OpenAPI documentation.

### How?

Add the POST endpoint to the Unstable version of the OpenAPI spec, following the same
pattern as the existing POST /contacts/{id}/notes endpoint.

<sub>Generated with Claude Code</sub>
Fixes:
- Remove company_id from request body (conflicts with path parameter)
- Add 401 Unauthorized response
- Clarify 404 description (company OR admin not found)
- Improve admin_id description (explain default behavior)
- Remove company_id from request examples

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
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

Comments