-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpops.html
More file actions
50 lines (50 loc) · 17.9 KB
/
pops.html
File metadata and controls
50 lines (50 loc) · 17.9 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
<!doctype html>
<html lang="en" dir="ltr" class="docs-wrapper plugin-docs plugin-id-default docs-version-current docs-doc-page docs-doc-id-pops/pops" data-has-hydrated="false">
<head>
<meta charset="UTF-8">
<meta name="generator" content="Docusaurus v3.10.0">
<title data-rh="true">Persisted Operations | Local Public Docs</title><meta data-rh="true" name="viewport" content="width=device-width,initial-scale=1"><meta data-rh="true" name="robots" content="noindex, nofollow"><meta data-rh="true" name="twitter:card" content="summary_large_image"><meta data-rh="true" property="og:url" content="https://docs.api.localstreaming.org/pops"><meta data-rh="true" property="og:locale" content="en"><meta data-rh="true" name="docusaurus_locale" content="en"><meta data-rh="true" name="docsearch:language" content="en"><meta data-rh="true" name="docusaurus_version" content="current"><meta data-rh="true" name="docusaurus_tag" content="docs-default-current"><meta data-rh="true" name="docsearch:version" content="current"><meta data-rh="true" name="docsearch:docusaurus_tag" content="docs-default-current"><meta data-rh="true" property="og:title" content="Persisted Operations | Local Public Docs"><meta data-rh="true" name="description" content="Persisted Operations (POPs) are pre-defined GQL operations. POP query responses are globally cacheable and deliverable from the edge for much faster response times than custom direct queries. POP mutation requests take advantage of global routing for faster overall network transit based on originating location."><meta data-rh="true" property="og:description" content="Persisted Operations (POPs) are pre-defined GQL operations. POP query responses are globally cacheable and deliverable from the edge for much faster response times than custom direct queries. POP mutation requests take advantage of global routing for faster overall network transit based on originating location."><link data-rh="true" rel="canonical" href="https://docs.api.localstreaming.org/pops"><link data-rh="true" rel="alternate" href="https://docs.api.localstreaming.org/pops" hreflang="en"><link data-rh="true" rel="alternate" href="https://docs.api.localstreaming.org/pops" hreflang="x-default"><script data-rh="true" type="application/ld+json">{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Persisted Operations","item":"https://docs.api.localstreaming.org/pops/"}]}</script><link rel="stylesheet" href="/assets/css/styles.b77ed532.css">
<script src="/assets/js/runtime~main.df43a785.js" defer="defer"></script>
<script src="/assets/js/main.ce997139.js" defer="defer"></script>
</head>
<body>
<svg style="display: none;"><defs>
<symbol id="theme-svg-external-link" viewBox="0 0 24 24"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"/></symbol>
</defs></svg>
<script>!function(){var t=function(){try{return new URLSearchParams(window.location.search).get("docusaurus-theme")}catch(t){}}()||function(){try{return window.localStorage.getItem("theme")}catch(t){}}();document.documentElement.setAttribute("data-theme",t||"light"),document.documentElement.setAttribute("data-theme-choice",t||"light")}(),function(){try{const c=new URLSearchParams(window.location.search).entries();for(var[t,e]of c)if(t.startsWith("docusaurus-data-")){var a=t.replace("docusaurus-data-","data-");document.documentElement.setAttribute(a,e)}}catch(t){}}()</script><div id="__docusaurus"><div role="region" aria-label="Skip to main content"><a class="skipToContent_oPtH" href="#__docusaurus_skipToContent_fallback">Skip to main content</a></div><nav aria-label="Main" class="theme-layout-navbar navbar navbar--fixed-top"><div class="navbar__inner"><div class="theme-layout-navbar-left navbar__items"><button aria-label="Toggle navigation bar" aria-expanded="false" class="navbar__toggle clean-btn" type="button"><svg width="30" height="30" viewBox="0 0 30 30" aria-hidden="true"><path stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="2" d="M4 7h22M4 15h22M4 23h22"></path></svg></button><a class="navbar__brand" href="/"><b class="navbar__title text--truncate">Local Public Docs</b></a></div><div class="theme-layout-navbar-right navbar__items navbar__items--right"><a class="navbar__item navbar__link" href="/graphql-api">GraphQL API</a><a aria-current="page" class="navbar__item navbar__link navbar__link--active" href="/pops">Persisted Operations</a><a class="navbar__item navbar__link" href="/http-api">HTTP API</a><a class="navbar__item navbar__link" href="/webhooks">Webhooks</a><div class="toggle_ki11 colorModeToggle_Hewu"><button class="clean-btn toggleButton_MMFG toggleButtonDisabled_Uw7m" type="button" disabled="" title="system mode" aria-label="Switch between dark and light mode (currently system mode)"><svg viewBox="0 0 24 24" width="24" height="24" aria-hidden="true" class="toggleIcon_k9hJ lightToggleIcon_lgto"><path fill="currentColor" d="M12,9c1.65,0,3,1.35,3,3s-1.35,3-3,3s-3-1.35-3-3S10.35,9,12,9 M12,7c-2.76,0-5,2.24-5,5s2.24,5,5,5s5-2.24,5-5 S14.76,7,12,7L12,7z M2,13l2,0c0.55,0,1-0.45,1-1s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S1.45,13,2,13z M20,13l2,0c0.55,0,1-0.45,1-1 s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S19.45,13,20,13z M11,2v2c0,0.55,0.45,1,1,1s1-0.45,1-1V2c0-0.55-0.45-1-1-1S11,1.45,11,2z M11,20v2c0,0.55,0.45,1,1,1s1-0.45,1-1v-2c0-0.55-0.45-1-1-1C11.45,19,11,19.45,11,20z M5.99,4.58c-0.39-0.39-1.03-0.39-1.41,0 c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0s0.39-1.03,0-1.41L5.99,4.58z M18.36,16.95 c-0.39-0.39-1.03-0.39-1.41,0c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0c0.39-0.39,0.39-1.03,0-1.41 L18.36,16.95z M19.42,5.99c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06c-0.39,0.39-0.39,1.03,0,1.41 s1.03,0.39,1.41,0L19.42,5.99z M7.05,18.36c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06 c-0.39,0.39-0.39,1.03,0,1.41s1.03,0.39,1.41,0L7.05,18.36z"></path></svg><svg viewBox="0 0 24 24" width="24" height="24" aria-hidden="true" class="toggleIcon_k9hJ darkToggleIcon_U96C"><path fill="currentColor" d="M9.37,5.51C9.19,6.15,9.1,6.82,9.1,7.5c0,4.08,3.32,7.4,7.4,7.4c0.68,0,1.35-0.09,1.99-0.27C17.45,17.19,14.93,19,12,19 c-3.86,0-7-3.14-7-7C5,9.07,6.81,6.55,9.37,5.51z M12,3c-4.97,0-9,4.03-9,9s4.03,9,9,9s9-4.03,9-9c0-0.46-0.04-0.92-0.1-1.36 c-0.98,1.37-2.58,2.26-4.4,2.26c-2.98,0-5.4-2.42-5.4-5.4c0-1.81,0.89-3.42,2.26-4.4C12.92,3.04,12.46,3,12,3L12,3z"></path></svg><svg viewBox="0 0 24 24" width="24" height="24" aria-hidden="true" class="toggleIcon_k9hJ systemToggleIcon_E5c0"><path fill="currentColor" d="m12 21c4.971 0 9-4.029 9-9s-4.029-9-9-9-9 4.029-9 9 4.029 9 9 9zm4.95-13.95c1.313 1.313 2.05 3.093 2.05 4.95s-0.738 3.637-2.05 4.95c-1.313 1.313-3.093 2.05-4.95 2.05v-14c1.857 0 3.637 0.737 4.95 2.05z"></path></svg></button></div><div class="navbarSearchContainer_bzqh"><div class="dsla-search-wrapper"><div class="dsla-search-field" data-tags="default,docs-default-current"></div></div></div></div></div><div role="presentation" class="navbar-sidebar__backdrop"></div></nav><div id="__docusaurus_skipToContent_fallback" class="theme-layout-main main-wrapper mainWrapper_MB5r"><div class="docsWrapper__sE8"><button aria-label="Scroll back to top" class="clean-btn theme-back-to-top-button backToTopButton_iEvu" type="button"></button><div class="docRoot_DfVB"><aside class="theme-doc-sidebar-container docSidebarContainer_c7NB"><div class="sidebarViewport_KYo0"><div class="sidebar_CUen"><nav aria-label="Docs sidebar" class="menu thin-scrollbar menu_jmj1"><ul class="theme-doc-sidebar-menu menu__list"><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-1 menu__list-item"><a class="menu__link" href="/"><span title="Home" class="linkLabel_fEdy">Home</span></a></li><li class="theme-doc-sidebar-item-category theme-doc-sidebar-item-category-level-1 menu__list-item menu__list-item--collapsed"><div class="menu__list-item-collapsible"><a class="categoryLink_ROYx menu__link menu__link--sublist" href="/graphql-api"><span title="GraphQL API" class="categoryLinkLabel_ufhF">GraphQL API</span></a><button aria-label="Expand sidebar category 'GraphQL API'" aria-expanded="false" type="button" class="clean-btn menu__caret"></button></div></li><li class="theme-doc-sidebar-item-category theme-doc-sidebar-item-category-level-1 menu__list-item menu__list-item--collapsed"><div class="menu__list-item-collapsible"><a class="categoryLink_ROYx menu__link menu__link--sublist" href="/http-api"><span title="HTTP API" class="categoryLinkLabel_ufhF">HTTP API</span></a><button aria-label="Expand sidebar category 'HTTP API'" aria-expanded="false" type="button" class="clean-btn menu__caret"></button></div></li><li class="theme-doc-sidebar-item-category theme-doc-sidebar-item-category-level-1 menu__list-item"><div class="menu__list-item-collapsible menu__list-item-collapsible--active"><a class="categoryLink_ROYx menu__link menu__link--sublist menu__link--active" aria-current="page" href="/pops"><span title="Persisted Operations" class="categoryLinkLabel_ufhF">Persisted Operations</span></a><button aria-label="Collapse sidebar category 'Persisted Operations'" aria-expanded="true" type="button" class="clean-btn menu__caret"></button></div><ul class="menu__list"><li class="theme-doc-sidebar-item-category theme-doc-sidebar-item-category-level-2 menu__list-item menu__list-item--collapsed"><div class="menu__list-item-collapsible"><a class="categoryLink_ROYx menu__link menu__link--sublist menu__link--sublist-caret" role="button" aria-expanded="false" tabindex="0" href="/pops/v1/addlike"><span title="v1" class="categoryLinkLabel_ufhF">v1</span></a></div></li></ul></li><li class="theme-doc-sidebar-item-category theme-doc-sidebar-item-category-level-1 menu__list-item menu__list-item--collapsed"><div class="menu__list-item-collapsible"><a class="categoryLink_ROYx menu__link menu__link--sublist" href="/webhooks"><span title="Webhooks" class="categoryLinkLabel_ufhF">Webhooks</span></a><button aria-label="Expand sidebar category 'Webhooks'" aria-expanded="false" type="button" class="clean-btn menu__caret"></button></div></li></ul></nav></div></div></aside><main class="docMainContainer_a9sJ"><div class="container padding-top--md padding-bottom--lg"><div class="row"><div class="col docItemCol_Qr34"><div class="docItemContainer_tjFy"><article><nav class="theme-doc-breadcrumbs breadcrumbsContainer_T5ub" aria-label="Breadcrumbs"><ul class="breadcrumbs"><li class="breadcrumbs__item"><a aria-label="Home page" class="breadcrumbs__link" href="/"><svg viewBox="0 0 24 24" class="breadcrumbHomeIcon_sfvy"><path d="M10 19v-5h4v5c0 .55.45 1 1 1h3c.55 0 1-.45 1-1v-7h1.7c.46 0 .68-.57.33-.87L12.67 3.6c-.38-.34-.96-.34-1.34 0l-8.36 7.53c-.34.3-.13.87.33.87H5v7c0 .55.45 1 1 1h3c.55 0 1-.45 1-1z" fill="currentColor"></path></svg></a></li><li class="breadcrumbs__item breadcrumbs__item--active"><span class="breadcrumbs__link">Persisted Operations</span></li></ul></nav><div class="tocCollapsible_wXna theme-doc-toc-mobile tocMobile_Ojys"><button type="button" class="clean-btn tocCollapsibleButton_iI2p">On this page</button></div><div class="theme-doc-markdown markdown"><header><h1>Persisted Operations</h1></header><p>Persisted Operations (POPs) are pre-defined GQL operations. POP query responses are globally cacheable and deliverable from the edge for much faster response times than custom direct queries. POP mutation requests take advantage of global routing for faster overall network transit based on originating location.</p>
<h2 class="anchor anchorTargetStickyNavbar_tleR" id="authentication">Authentication<a href="#authentication" class="hash-link" aria-label="Direct link to Authentication" title="Direct link to Authentication" translate="no"></a></h2>
<h3 class="anchor anchorTargetStickyNavbar_tleR" id="api-user-authentication">API user authentication<a href="#api-user-authentication" class="hash-link" aria-label="Direct link to API user authentication" title="Direct link to API user authentication" translate="no"></a></h3>
<p>API users are assigned and associated with exactly one station. See <a class="" href="/http-api/api-auth">HTTP API - API Auth</a> for information about how to obtain a token.</p>
<h2 class="anchor anchorTargetStickyNavbar_tleR" id="making-a-request">Making a request<a href="#making-a-request" class="hash-link" aria-label="Direct link to Making a request" title="Direct link to Making a request" translate="no"></a></h2>
<p>A POPs request is comprised of:</p>
<ol>
<li class="">the base URL,</li>
<li class="">a version identifier,</li>
<li class="">the POP name, and</li>
<li class="">any operation parameters (arguments).</li>
</ol>
<p>The complete format is: <code>{basUrl}/{versionIdentifier}/{popName}?{operationParameters}</code></p>
<p>Example: <code>https://dev.api.localstreaming.org/pops/v1/getMovies?country=US&genreVibes=food&genreVibes=drama&sortByField=createdAt&sortByOrder=desc&stationId=93c39d90-e15f-4cf3-b719-f22296eb853a</code></p>
<h3 class="anchor anchorTargetStickyNavbar_tleR" id="base-url">Base URL<a href="#base-url" class="hash-link" aria-label="Direct link to Base URL" title="Direct link to Base URL" translate="no"></a></h3>
<h4 class="anchor anchorTargetStickyNavbar_tleR" id="development">Development<a href="#development" class="hash-link" aria-label="Direct link to Development" title="Direct link to Development" translate="no"></a></h4>
<p><code>https://dev.api.localstreaming.org/pops</code></p>
<h4 class="anchor anchorTargetStickyNavbar_tleR" id="production">Production<a href="#production" class="hash-link" aria-label="Direct link to Production" title="Direct link to Production" translate="no"></a></h4>
<p><code>https://api.localstreaming.org/pops</code></p>
<h3 class="anchor anchorTargetStickyNavbar_tleR" id="version-identifiers">Version identifiers<a href="#version-identifiers" class="hash-link" aria-label="Direct link to Version identifiers" title="Direct link to Version identifiers" translate="no"></a></h3>
<h4 class="anchor anchorTargetStickyNavbar_tleR" id="v1"><code>v1</code><a href="#v1" class="hash-link" aria-label="Direct link to v1" title="Direct link to v1" translate="no"></a></h4>
<p>The initial version identifier for production-ready POPs.</p>
<p>Any breaking changes made to these POPs queries in the future will require a new version identifier.</p>
<h4 class="anchor anchorTargetStickyNavbar_tleR" id="experimental"><code>experimental</code><a href="#experimental" class="hash-link" aria-label="Direct link to experimental" title="Direct link to experimental" translate="no"></a></h4>
<div class="theme-admonition theme-admonition-danger admonition_WCGJ alert alert--danger"><div class="admonitionHeading_GCBg"><span class="admonitionIcon_L39b"><svg viewBox="0 0 12 16"><path fill-rule="evenodd" d="M5.05.31c.81 2.17.41 3.38-.52 4.31C3.55 5.67 1.98 6.45.9 7.98c-1.45 2.05-1.7 6.53 3.53 7.7-2.2-1.16-2.67-4.52-.3-6.61-.61 2.03.53 3.33 1.94 2.86 1.39-.47 2.3.53 2.27 1.67-.02.78-.31 1.44-1.13 1.81 3.42-.59 4.78-3.42 4.78-5.56 0-2.84-2.53-3.22-1.25-5.61-1.52.13-2.03 1.13-1.89 2.75.09 1.08-1.02 1.8-1.86 1.33-.67-.41-.66-1.19-.06-1.78C8.18 5.31 8.68 2.45 5.05.32L5.03.3l.02.01z"></path></svg></span>danger</div><div class="admonitionContent_pbrs"><p>Do not use operations in this version identifier for production applications.</p></div></div>
<p>In progress or incomplete POPs that may change dramatically before being added to a production-ready version identifier.</p>
<h3 class="anchor anchorTargetStickyNavbar_tleR" id="pop-name">POP name<a href="#pop-name" class="hash-link" aria-label="Direct link to POP name" title="Direct link to POP name" translate="no"></a></h3>
<p>Determines which operation will be run. E.g., <code>getStation</code>, <code>getShow</code>, <code>getLikes</code>, etc.</p>
<h3 class="anchor anchorTargetStickyNavbar_tleR" id="http-verbs">HTTP verbs<a href="#http-verbs" class="hash-link" aria-label="Direct link to HTTP verbs" title="Direct link to HTTP verbs" translate="no"></a></h3>
<p>For POPs executing GraphQL queries, use the HTTP <code>GET</code> verb.</p>
<p>For POPs executing GraphQL mutations, use the HTTP <code>POST</code> verb.</p>
<h3 class="anchor anchorTargetStickyNavbar_tleR" id="query-parameters">Query parameters<a href="#query-parameters" class="hash-link" aria-label="Direct link to Query parameters" title="Direct link to Query parameters" translate="no"></a></h3>
<p>The GraphQL operation arguments are set via HTTP query parameters.</p>
<p>E.g., to set the <code>stationId</code> for a POP request, add <code>?stationId={stationId}</code> as a query parameter.</p>
<p>Query parameters can be set multiple times to create an array: <code>?genreVibes=food&genreVibes=drama</code>.</p></div></article><nav class="docusaurus-mt-lg pagination-nav" aria-label="Docs pages"></nav></div></div><div class="col col--3"><div class="tableOfContents_XG6w thin-scrollbar theme-doc-toc-desktop"><ul class="table-of-contents table-of-contents__left-border"><li><a href="#authentication" class="table-of-contents__link toc-highlight">Authentication</a><ul><li><a href="#api-user-authentication" class="table-of-contents__link toc-highlight">API user authentication</a></li></ul></li><li><a href="#making-a-request" class="table-of-contents__link toc-highlight">Making a request</a><ul><li><a href="#base-url" class="table-of-contents__link toc-highlight">Base URL</a></li><li><a href="#version-identifiers" class="table-of-contents__link toc-highlight">Version identifiers</a></li><li><a href="#pop-name" class="table-of-contents__link toc-highlight">POP name</a></li><li><a href="#http-verbs" class="table-of-contents__link toc-highlight">HTTP verbs</a></li><li><a href="#query-parameters" class="table-of-contents__link toc-highlight">Query parameters</a></li></ul></li></ul></div></div></div></div></main></div></div></div><footer class="theme-layout-footer footer footer--dark"><div class="container container-fluid"><div class="footer__bottom text--center"><div class="footer__copyright">Copyright © 2026 Cascade Public Media.</div></div></div></footer></div>
</body>
</html>