From 91b5a790ec414e54f3b69de257be7c0082c896c7 Mon Sep 17 00:00:00 2001 From: Steve Henry Date: Mon, 31 Aug 2026 17:17:07 +0100 Subject: [PATCH 1/2] Fix three fern check errors blocking SDK generation `fern check` has been failing on main with 3 errors in the Preview namespace, which blocks all SDK preview generation and therefore any SDK release. Two are generated-type name collisions: Fern names an endpoint's request wrapper after the operation, which collided with the body type generated from the $ref'd component. Resolved with the `*RequestBody` rename convention already used seven times in this file. The third is a dangling type reference. `updateArticle` and `stageArticleDraft` both $ref `update_article_request`, and `'/articles/{id}': put: null` removes the former from Preview. Fern then prunes the schema while `stageArticleDraft` still references it. Given `stageArticleDraft` documents different semantics anyway (it ignores non-versioned fields), it now has its own schema. No wire shapes change. No endpoint is added or removed. Request and response bodies are byte-identical. Co-Authored-By: Claude Opus 5 (1M context) --- descriptions/0/api.intercom.io.yaml | 133 +++++++++++++++++++++++++++- fern/preview-openapi-overrides.yml | 6 ++ 2 files changed, 138 insertions(+), 1 deletion(-) diff --git a/descriptions/0/api.intercom.io.yaml b/descriptions/0/api.intercom.io.yaml index 4c351bab..69aa3036 100644 --- a/descriptions/0/api.intercom.io.yaml +++ b/descriptions/0/api.intercom.io.yaml @@ -1995,7 +1995,7 @@ paths: content: application/json: schema: - "$ref": "#/components/schemas/update_article_request" + "$ref": "#/components/schemas/stage_article_draft_request_body" examples: Draft staged: summary: Stage a draft @@ -40760,6 +40760,137 @@ components: example: - en - fr + stage_article_draft_request_body: + description: You can Stage a Draft for an Article + type: object + title: Stage Article Draft Request Payload + nullable: true + properties: + title: + type: string + description: The title of the article.For multilingual articles, this will + be the title of the default language's content. + example: Thanks for everything + description: + type: string + description: The description of the article. For multilingual articles, + this will be the description of the default language's content. + example: Description of the Article + body: + type: string + description: The content of the article in HTML. For multilingual articles, this + will be the body of the default language's content. Mutually exclusive with `body_markdown`. + example: "

This is the body in html

" + body_markdown: + type: string + description: The content of the article in markdown. For multilingual articles, this + will be the body of the default language's content. An alternative to `body` — you + can provide content as markdown instead of HTML. Mutually exclusive with `body`. + example: "## Updated heading\n\nNew content.\n" + author_id: + type: integer + description: The id of the author of the article. For multilingual articles, + this will be the id of the author of the default language's content. Must + be a teammate on the help center's workspace. + example: 1295 + state: + type: string + description: Whether the article will be `published` or will be a `draft`. + Omitting this field leaves the publish state unchanged, so a draft stays + a draft and an edit to a published article goes live immediately unless + that article already has a pending draft or a scheduled publish time is + set in the same request. The `PUT /articles/{id}/draft` endpoint ignores + this field and always stages a draft. For multilingual articles, this + will be the state of the default language's content. + enum: + - published + - draft + example: draft + parent_id: + type: string + description: The id of the article's parent collection or section. An article + without this field stands alone. + example: '18' + parent_type: + type: string + description: The type of parent, which can either be a `collection` or `section`. + example: collection + parent_ids: + type: array + description: The ids of the parent collections to place this article in. + Send an empty array to remove the article from all collections. When + provided, this takes precedence over `parent_id` and `parent_type`. + items: + type: integer + example: + - 18 + - 19 + translated_content: + "$ref": "#/components/schemas/article_translated_content" + folder_id: + type: integer + nullable: true + description: The ID of the folder to place this article in, or null to remove it from its folder. + example: 6 + audience_ids: + type: array + nullable: true + description: >- + The list of audience IDs to assign to this article for Fin AI Agent targeting. + Sending a top-level `audience_ids` broadcasts the same set to every locale. + Sending `audience_ids: []` clears all audience memberships from every locale. + For per-locale targeting, use `translated_content..audience_ids` instead. + Sending both top-level and per-locale in the same request causes top-level to win. + Unknown audience IDs return a 404 error. No partial commit occurs. + items: + type: integer + example: + - 1 + - 2 + ai_chatbot_availability: + type: boolean + description: Whether the article should be available for AI Chatbot (Fin). + For multilingual articles, this sets the default language's availability. + example: true + ai_copilot_availability: + type: boolean + description: Whether the article should be available for AI Copilot. For + multilingual articles, this sets the default language's availability. + example: true + ai_sales_agent_availability: + type: boolean + description: Whether the article should be available for AI Sales Agent. + For multilingual articles, this sets the default language's availability. + example: true + scheduled_publish_at: + type: string + format: date-time + nullable: true + description: >- + ISO 8601 timestamp at which to schedule a future publish of the article. + When set together with `state: "published"`, the article is scheduled + instead of published immediately. Setting `null` cancels a pending + publish schedule. Timestamps in the past or equal to the current time + are rejected with 400 `parameter_invalid` — the value must be strictly + in the future. Combining with `state: "draft"` returns 400 + `parameter_invalid`. Sending in the same request as + `scheduled_unpublish_at` returns 400 — only one pending schedule per + article. Empty string returns 400 `parameter_invalid`. + example: '2026-12-31T09:00:00Z' + scheduled_unpublish_at: + type: string + format: date-time + nullable: true + description: >- + ISO 8601 timestamp at which to schedule a future unpublish of the article. + Setting `null` cancels a pending unpublish schedule. Timestamps in the + past or equal to the current time are rejected with 400 + `parameter_invalid` — the value must be strictly in the future. Rejected + with 400 `parameter_invalid` if the article has never been published. + Sending in the same request as `scheduled_publish_at` returns 400 — only + one pending schedule per article. Empty string returns 400 + `parameter_invalid`. + example: '2026-12-31T17:00:00Z' update_article_request: description: You can Update an Article type: object diff --git a/fern/preview-openapi-overrides.yml b/fern/preview-openapi-overrides.yml index 1fa627e8..c3dafcac 100644 --- a/fern/preview-openapi-overrides.yml +++ b/fern/preview-openapi-overrides.yml @@ -137,6 +137,12 @@ components: x-fern-type-name: ReplyConversationRequestBody update_article_request: x-fern-type-name: UpdateArticleRequestBody + stage_article_draft_request_body: + x-fern-type-name: UpdateArticleRequestBody + publish_article_draft_request: + x-fern-type-name: PublishArticleDraftRequestBody + create_conversation_attribute_option_request: + x-fern-type-name: CreateConversationAttributeOptionRequestBody update_ticket_type_request: x-fern-type-name: UpdateTicketTypeRequestBody single_filter_search_request: From 66a01c2b225911820090b56a1f0245e749600b2b Mon Sep 17 00:00:00 2001 From: Steve Henry Date: Tue, 1 Sep 2026 13:36:18 +0100 Subject: [PATCH 2/2] Drop the now-vestigial update_article_request type-name override With the draft-staging endpoint pointing at its own schema, update_article_request is referenced by no live Preview endpoint, so its x-fern-type-name override no longer resolves to anything. Removing it also means only one schema maps to UpdateArticleRequestBody, rather than two relying on Preview pruning to avoid colliding. fern check stays at 0 errors and the generated type keeps its name and all 17 properties. Co-Authored-By: Claude Opus 5 (1M context) --- fern/preview-openapi-overrides.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/fern/preview-openapi-overrides.yml b/fern/preview-openapi-overrides.yml index c3dafcac..c90b575e 100644 --- a/fern/preview-openapi-overrides.yml +++ b/fern/preview-openapi-overrides.yml @@ -135,8 +135,6 @@ components: x-fern-type-name: MergeConversationsRequestBody reply_conversation_request: x-fern-type-name: ReplyConversationRequestBody - update_article_request: - x-fern-type-name: UpdateArticleRequestBody stage_article_draft_request_body: x-fern-type-name: UpdateArticleRequestBody publish_article_draft_request: