{"openapi":"3.0.0","info":{"title":"SpeakUp Customer API","description":"Interact with the SpeakUp API to manage podcasts.","version":"2.1.0"},"components":{"schemas":{"PluginSettingsHeader":{"type":"object","properties":{"x-api-key":{"type":"string","description":"API key for publisher authorization","nullable":false}},"required":["x-api-key"]},"PluginSettingsQuery":{"type":"object","properties":{"siteId":{"type":"string","description":"ID of the site to retrieve settings for","nullable":false}},"required":["siteId"]},"PluginSettingsResponse":{"type":"object","properties":{"200":{"type":"object","description":"Request was successful and the settings were retrieved.","properties":{"active":{"type":"boolean","description":"Indicates if the site is active and therefore can use the plugin."},"articlesPublishedSince":{"type":"integer","description":"Seconds since posix epoch (January 1, 1970) when the first article was published. 0 means all the articles."},"player":{"type":"object","properties":{"layout":{"type":"string"}}}},"required":["active","articlesPublishedSince","player"]},"4xx":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]}}},"PodcastHeader":{"type":"object","properties":{"x-api-key":{"type":"string","description":"API key for publisher authorization","nullable":false}},"required":["x-api-key"]},"PodcastCreateBody":{"type":"object","properties":{"siteId":{"type":"string","description":"ID of the site where the podcast will be published."},"publisherId":{"type":"string","description":"ID of the publisher of the podcast in the site identified by the siteId."},"publishDate":{"type":"string","format":"date-time","description":"ISO 8601 date string of when the article was published. This string must include timezone information (e.g., 2025-05-09T10:00:00Z for UTC, or 2025-05-09T12:00:00+02:00 for a specific offset)."},"title":{"type":"string","description":"Title of the podcast episode.","minLength":10},"html":{"type":"string","description":"HTML content of the article."},"url":{"type":"string","description":"URL of the article. Providing a URL for a podcast that already exists will make the call to return the existing podcast id."},"isPremium":{"type":"boolean","description":"Indicates if the article can be read only by premium users."},"imageURL":{"type":"string","description":"URL of the image associated with the article. Will be shown in the podcast. The web service returning the image, will be queried against the HEAD method to check if the image is valid."},"description":{"type":"string","description":"Description of the article"},"author":{"type":"string","description":"Author of the article. If not provided or not valid, Site name will be used instead."}},"required":["siteId","publisherId","publishDate","title","html","url"]},"PodcastCreateResponse":{"type":"object","properties":{"200":{"type":"object","properties":{"message":{"type":"string"},"podcastId":{"type":"string"}},"description":"Podcast already exists and is available. PodcastId is returned.","required":["message","podcastId"]},"202":{"type":"object","properties":{"message":{"type":"string"},"podcastId":{"type":"string"}},"description":"Podcast creation has been scheduled. The podcast will be available soon.","required":["message","podcastId"]},"204":{"type":"object","properties":{},"description":"API call was successful, but no podcast was created or scheduled due to business logic defined for the current site."},"500":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]},"4xx":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]}}},"PodcastUpdateBody":{"type":"object","properties":{"siteId":{"type":"string","description":"ID of the site where the podcast is published."},"publisherId":{"type":"string","description":"ID of the publisher that owns the podcast."},"podcastId":{"type":"string","description":"ID of the podcast to update."},"changes":{"type":"object","properties":{"author":{"type":"string","description":"Updated author of the article."},"title":{"type":"string","description":"Updated title of the article."},"html":{"type":"string","description":"Updated HTML content of the article."},"imageURL":{"type":"string","description":"Updated image URL of the article."},"description":{"type":"string","description":"Updated description of the article."},"published":{"type":"boolean","description":"Updated published status of the article."},"url":{"type":"string","description":"Updated URL of the article."},"publishDate":{"type":"string","format":"date-time","description":"Updated publish date of the article."}}}},"required":["siteId","publisherId","podcastId","changes"]},"PodcastUpdateResponse":{"type":"object","properties":{"202":{"type":"object","description":"Podcast update request has been accepted. Update has been scheduled.","properties":{"message":{"type":"string"},"podcastId":{"type":"string"}},"required":["message","podcastId"]},"204":{"type":"object","description":"API call successful, but there was nothing to update."},"404":{"type":"object","description":"Podcast not found. The provided podcastId does not match any existing podcast.","properties":{"message":{"type":"string"}},"required":["message"]},"500":{"type":"object","description":"Internal server error. Something went wrong while processing the request.","properties":{"message":{"type":"string"}},"required":["message"]},"4xx":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]}}},"PodcastUpdateDemandedBody":{"type":"object","properties":{"siteId":{"type":"string","description":"ID of the site where the podcast will be published."},"publisherId":{"type":"string","description":"ID of the publisher of the podcast in the site identified by the siteId."},"url":{"type":"string","description":"URL of the article. Providing a URL for a podcast that already exists will make the call to return the existing podcast id."}},"required":["siteId","publisherId","url"]},"PodcastUpdateDemandedResponse":{"type":"object","properties":{"200":{"type":"object","properties":{"message":{"type":"string"}},"description":"Podcast is already up to date, so no update is required.","required":["message"]},"202":{"type":"object","properties":{"message":{"type":"string"}},"description":"Podcast update has been scheduled. The new podcast will be available soon.","required":["message"]},"204":{"type":"object","properties":{},"description":"API call was successful, but no podcast was created or scheduled due to business logic defined for the current site."},"500":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]},"4xx":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]}}},"PublisherSitesHeader":{"type":"object","properties":{"x-api-key":{"type":"string","description":"API key for publisher authorization","nullable":false}},"required":["x-api-key"]},"PublisherSitesQuery":{"type":"object","properties":{"publisherId":{"type":"string","description":"ID of the publisher to retrieve sites for","nullable":false},"activeOnly":{"type":"boolean","description":"Filter to return only active sites","nullable":true}},"required":["publisherId"]},"PublisherSitesResponse":{"type":"object","properties":{"200":{"type":"object","description":"Request was successful and the sites for the publisher are returned.","properties":{"sites":{"type":"object","additionalProperties":{"type":"object","properties":{"name":{"type":"string"},"domain":{"type":"string"},"childDomains":{"type":"array","items":{"type":"string"}},"setup":{"type":"boolean"},"active":{"type":"boolean"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"required":["name","domain","setup","active","createdAt"]}}}},"403":{"description":"Publisher not found, not active or not authorized","type":"object","properties":{"message":{"type":"string"}}}}}}},"paths":{"/plugin/settings":{"post":{"responses":{"405":{"description":"Method not allowed","content":{"application/json":{"schema":{"type":"object","description":"Method not allowed","properties":{"message":{"type":"string"}},"required":["message"]}}}}}},"put":{"responses":{"405":{"description":"Method not allowed","content":{"application/json":{"schema":{"type":"object","description":"Method not allowed","properties":{"message":{"type":"string"}},"required":["message"]}}}}}},"get":{"operationId":"GET /plugin/settings","description":"Retrieve plugin settings and configuration for a site","parameters":[{"schema":{"type":"string","nullable":false},"in":"query","name":"siteId","required":true,"description":"ID of the site to retrieve settings for"},{"schema":{"type":"string","nullable":false},"in":"header","name":"x-api-key","required":true,"description":"API key for publisher authorization"}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PluginSettingsResponse/properties/200"}}}},"4XX":{"description":"Default Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PluginSettingsResponse/properties/4xx"}}}},"default":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string","default":"UnexpectedStatusCode"}},"required":["error"],"additionalProperties":false}}}}}}},"/podcast":{"get":{"responses":{"405":{"description":"Method not allowed","content":{"application/json":{"schema":{"type":"object","description":"Method not allowed","properties":{"message":{"type":"string"}},"required":["message"]}}}}}},"delete":{"responses":{"405":{"description":"Method not allowed","content":{"application/json":{"schema":{"type":"object","description":"Method not allowed","properties":{"message":{"type":"string"}},"required":["message"]}}}}}},"post":{"operationId":"POST /podcast","description":"Create a new podcast from article content","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PodcastCreateBody"}}}},"parameters":[{"schema":{"type":"string","nullable":false},"in":"header","name":"x-api-key","required":true,"description":"API key for publisher authorization"}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PodcastCreateResponse/properties/200"}}}},"202":{"description":"Default Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PodcastCreateResponse/properties/202"}}}},"204":{"description":"Default Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PodcastCreateResponse/properties/204"}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PodcastCreateResponse/properties/500"}}}},"4XX":{"description":"Default Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PodcastCreateResponse/properties/4xx"}}}},"default":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string","default":"UnexpectedStatusCode"}},"required":["error"],"additionalProperties":false}}}}}},"patch":{"operationId":"PATCH /podcast","description":"Update an existing podcast with partial changes","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PodcastUpdateBody"}}}},"parameters":[{"schema":{"type":"string","nullable":false},"in":"header","name":"x-api-key","required":true,"description":"API key for publisher authorization"}],"responses":{"202":{"description":"Default Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PodcastUpdateResponse/properties/202"}}}},"204":{"description":"Default Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PodcastUpdateResponse/properties/204"}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PodcastUpdateResponse/properties/500"}}}},"4XX":{"description":"Default Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PodcastUpdateResponse/properties/4xx"}}}},"default":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string","default":"UnexpectedStatusCode"}},"required":["error"],"additionalProperties":false}}}}}},"put":{"operationId":"PUT /podcast","description":"Check if the provided URL is suitable for text content evaluation and synthesization into a podcast","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PodcastUpdateDemandedBody"}}}},"parameters":[{"schema":{"type":"string","nullable":false},"in":"header","name":"x-api-key","required":true,"description":"API key for publisher authorization"}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PodcastUpdateDemandedResponse/properties/200"}}}},"202":{"description":"Default Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PodcastUpdateDemandedResponse/properties/202"}}}},"204":{"description":"Default Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PodcastUpdateDemandedResponse/properties/204"}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PodcastUpdateDemandedResponse/properties/500"}}}},"4XX":{"description":"Default Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PodcastUpdateDemandedResponse/properties/4xx"}}}},"default":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string","default":"UnexpectedStatusCode"}},"required":["error"],"additionalProperties":false}}}}}}},"/publisher/sites":{"post":{"responses":{"405":{"description":"Method not allowed","content":{"application/json":{"schema":{"description":"Method not allowed","type":"object","properties":{"message":{"type":"string"}}}}}}}},"put":{"responses":{"405":{"description":"Method not allowed","content":{"application/json":{"schema":{"description":"Method not allowed","type":"object","properties":{"message":{"type":"string"}}}}}}}},"patch":{"responses":{"405":{"description":"Method not allowed","content":{"application/json":{"schema":{"description":"Method not allowed","type":"object","properties":{"message":{"type":"string"}}}}}}}},"delete":{"responses":{"405":{"description":"Method not allowed","content":{"application/json":{"schema":{"description":"Method not allowed","type":"object","properties":{"message":{"type":"string"}}}}}}}},"get":{"operationId":"GET /publisher/sites","description":"Retrieve all sites associated with a publisher","parameters":[{"schema":{"type":"string","nullable":false},"in":"query","name":"publisherId","required":true,"description":"ID of the publisher to retrieve sites for"},{"schema":{"type":"boolean","nullable":true},"in":"query","name":"activeOnly","required":false,"description":"Filter to return only active sites"},{"schema":{"type":"string","nullable":false},"in":"header","name":"x-api-key","required":true,"description":"API key for publisher authorization"}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublisherSitesResponse/properties/200"}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublisherSitesResponse/properties/403"}}}}}}}},"servers":[{"url":"https://api.speakup.ai/v2"}]}
