Skip to content

Align the 2.17 and Preview audience and dynamic content endpoints with what the API does - #755

Merged
markdennis22 merged 2 commits into
mainfrom
markdennis/2-17-audiences-dynamic-content
Oct 23, 2026
Merged

markdennis22 merged 2 commits into
mainfrom
markdennis/2-17-audiences-dynamic-content

Conversation

@markdennis22

@markdennis22 markdennis22 commented Oct 22, 2026 •

Copy link
Copy Markdown
Contributor

Why?

The 2.17 and Preview specs for the audience and dynamic content endpoints didn't match the API. The role predicate examples showed values the API never returns, predicate.value was typed as a string, and several error responses were missing or worded differently from what the API sends. The Preview SDK is generated from the Preview spec, so its next regeneration changes Predicate.value from a string to unknown, because the API accepts and returns strings, numbers, booleans, arrays and null. Predicate also gains an optional predicates list, and deleteAudience, createDynamicContent and updateDynamicContent gain a 400 error. The stable SDKs aren't generated from 2.17, so they are unaffected.

How?

Applies the same edit to 2.17 and Preview. Corrects the audience and dynamic content endpoints and schemas to match the API's current behaviour, and adds the OAuth scopes each endpoint accepts to its description.

Generated with Claude Code

…API does

Corrects the role predicate examples and the predicate value type, documents the error responses as the API sends them, notes the PATCH route and HTML-escaped names, and adds the accepted OAuth scopes to each operation.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
cathalging
cathalging previously approved these changes Oct 23, 2026

@cathalging cathalging left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving: the 2.17 changes match how the API behaves. Preview (descriptions/0) still has the old Audiences and Dynamic Content text, though, including predicate.value as a string, the eq/user role example and the read-only scope lines. The next version cut would undo this fix, so a Preview change is needed as a follow-up. Once Preview is updated, Predicate.value stops being typed as a string in the Preview SDK, which is worth noting in the release notes.

Optional: per_page on list dynamic contents now has maximum: 50, which contradicts "values above 50 are reduced".

~ Automated via Claude (about: https://github.com/intercom/claude-plugins/blob/main/plugins/base/docs/external-message-attribution.md)

Ports the 2.17 changes to the same operations and schemas in the Preview spec, so Preview matches what the API does too. In the Preview SDK, `Predicate.value` becomes `unknown` because the API accepts and returns strings, numbers, booleans, arrays and null.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
@markdennis22 markdennis22 changed the title Align the 2.17 audience and dynamic content endpoints with what the API does Align the 2.17 and Preview audience and dynamic content endpoints with what the API does Oct 23, 2026

@cathalging cathalging left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Re-approving: the Preview changes match 2.17 and how the API behaves. Still optional: per_page with maximum: 50 suggests larger values are rejected, but they're reduced to 50.

~ Automated via Claude (about: https://github.com/intercom/claude-plugins/blob/main/plugins/base/docs/external-message-attribution.md)

@markdennis22
markdennis22 merged commit df1366c into main Oct 23, 2026
4 checks passed
@markdennis22
markdennis22 deleted the markdennis/2-17-audiences-dynamic-content branch October 23, 2026 10:11
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.

2 participants