Meta tags:
description= Use the x-fern-streaming extension to model streaming endpoints;
Headings (most frequently used words):
server, sent, events, and, streaming, apis, json, stream, parameter, terminator, message, multipart, file, upload, extensions, overview, documentation, api, definitions, resources, company, team, enterprise, feature,
Text of the page (most frequently used words):
#streaming (15), api (14), overview (13), the (13), fern (12), server (12), and (11), your (11), names (11), type (10), text (10), for (10), openapi (9), json (9), schemas (8), response (8), stream (8), endpoints (8), sent (8), events (8), components (7), yml (7), this (6), page (6), chat (6), terminator (6), sse (6), message (6), authentication (6), definitions (5), availability (5), sync (5), specification (5), servers (5), overrides (5), reference (4), multipart (4), string (4), properties (4), object (4), ref (4), request (4), format (4), post (4), logs (4), paths (4), parameter (4), apis (4), you (4), data (4), any (4), audiences (4), examples (4), sdk (4), grpc (3), ask (3), documentation (3), done (3), have (3), that (3), responses (3), schema (3), webhooks (3), form (3), uploads (3), http (3), generators (3), ignoring (3), elements (3), definition (3), import (2), configure (2), specifications (2), english (2), company (2), support (2), openrpc (2), asyncapi (2), soc (2), extensions (2), chatchunk (2), condition (2), simply (2), specify (2), with (2), application (2), content (2), 200 (2), then (2), questions (2), chatbot (2), returns (2), seen (2), below (2), feature (2), available (2), team (2), enterprise (2), true (2), extension (2), markdown (2), start (2), free (2), log (2), book (2), demo (2), errors (2), global (2), headers (2), method (2), url (2), version (2), overlays (2), project (2), structure (2), what (2), index (2), level (2), llms (2), txt (2), terms, service, privacy, policy, brand, kit, pricing, blog, resources, cli, docs, sdks, 2026, birch, solutions, inc, postman, checking, status, next, file, upload, previous, edit, yes, was, helpful, number, tokens, well, ordinary, has, become, common, practice, controls, whether, streamed, not, supports, pattern, first, class, way, some, send, standalone, signal, complete, example, openai, sends, final, can, field, make, sure, include, keys, event, only, get, started, reach, out, buildwithfern, com, plans, add, operation, series, chunks, allows, represent, are, more, actions, view, copy, question, use, model, scroll, top, light, export, depending, other, packages, environments, imports, websockets, bytes, types, error, handling, services, group, rpc, methods, bindings, formats, publish, subscribe, operations, fastapi, templating, retry, behavior, pagination, idempotency, property, tag, display, variables, explorer, control, enum, descriptions, default, values, base, path, integrate, framework, search, agents, root, append,
Text of the page (random words):
server sent events and streaming apis fern documentation for ai agents a documentation index is available at the root level at llms txt append llms txt to any url for a page level index or md for the markdown version of any page search ask ai book a demo log in start for free overview what is an api definition project structure openapi overview overlays overrides authentication servers sync your specification endpoints http json endpoints webhooks multipart form uploads server sent events extensions integrate your server framework generators yml reference asyncapi openrpc grpc fern definition what is an api definition project structure overview overlays overrides authentication servers sync your specification http json endpoints webhooks multipart form uploads server sent events overview api version audiences availability base path default values enum descriptions names and availability request response examples api explorer control global headers ignoring elements sdk method names sdk variables tag display names parameter names property names idempotency pagination retry behavior schema names server names and url templating fastapi generators yml reference overview overrides authentication servers sync your specification publish subscribe operations message formats message bindings overview audiences availability request response examples ignoring elements server names overview overrides authentication servers sync your specification json rpc methods overview audiences availability request response examples ignoring elements sdk method names sdk group names server names overview overrides authentication servers sync your specification grpc services streaming error handling generators yml reference overview authentication types overview http json endpoints multipart form uploads bytes server sent events webhooks websockets errors imports examples audiences availability overview environments global headers errors packages depending on other apis export to openapi book a demo log in start for free english light on this page json streaming server sent events terminator message stream parameter scroll to top openapi endpoints server sent events and streaming apis use the x fern streaming extension to model streaming endpoints ask a question copy page view as markdown more actions the x fern streaming extension allows you to represent endpoints that are streaming json streaming if your api returns a series of json chunks as seen below 1 text hi i am a 2 text chatbot do you have any 3 text questions for me then simply add the x fern streaming true to your openapi operation openapi yml 1 paths 2 logs 3 post 4 x fern streaming true 5 responses 6 200 7 content 8 application json 9 schema 10 ref components schemas chat 11 components 12 schemas 13 chat 14 type object 15 properties 16 text 17 type string server sent events team and enterprise feature this feature is available only for the team and enterprise plans to get started reach out to support buildwithfern com if your api returns server sent events sse with the data and event keys as seen below 1 data text hi i am a 2 data text chatbot do you have any 3 data text questions for me then make sure to include format sse openapi yml 1 paths 2 logs 3 post 4 x fern streaming 5 format sse 6 responses 7 200 8 content 9 application json 10 schema 11 ref components schemas chat 12 components 13 schemas 14 chat 15 type object 16 properties 17 text 18 type string terminator message some sse apis send a standalone terminator message to signal that the stream is complete for example openai s api sends done as a final message you can specify this with the terminator field openapi yml 1 paths 2 logs 3 post 4 x fern streaming 5 format sse 6 terminator done 7 responses and schemas stream parameter it has become common practice for endpoints to have a stream parameter that controls whether the response is streamed or not fern supports this pattern in a first class way simply specify the stream condition as well as the ordinary response and the streaming response openapi yml 1 paths 2 logs 3 post 4 x fern streaming 5 format sse 6 terminator done 7 stream condition request stream 8 response 9 ref components schemas chat 10 response stream 11 ref components schemas chatchunk 12 components 13 schemas 14 chat 15 type object 16 properties 17 text 18 type string 19 tokens 20 type number 21 chatchunk 22 type object 23 properties 24 text 25 type string was this page helpful yes no edit this page previous multipart file upload next extensions overview checking status soc 2 soc 2 type ii 2026 fern birch solutions inc a postman company documentation sdks docs ask fern cli reference api definitions openapi asyncapi openrpc grpc resources blog support pricing company brand kit privacy policy terms of service api definitions api definitions import and configure your api specifications english api definitions api definitions import and configure your api specifications
|