openapi: 3.0.2
info:
  title: Automation API (All)
  version: ''
  license:
    name: Proprietary
    url: https://www.salesforce.com/company/legal/sfdc-website-terms-of-service/
  description: "Welcome to the documentation for the Automation API. This documentation\n\
    describes the functionality available in both current and deprecated\nversions\
    \ of API methods. You can also review the\n[documentation for only the current\
    \ API methods](/dev/automation/documentation/current).\n## Summary\nThe Quip Automation\
    \ API provides read/write access to Quip, enabling you to\nautomate processes\
    \ and integrate Quip with other products you or your\ncompany uses.\n\nThe Automation\
    \ API is\n<a href=\"https://en.wikipedia.org/wiki/Representational_State_Transfer\"\
    \ target=\"_blank\">REST</a>-based.\nResponses are <a href=\"http://www.json.org/\"\
    \ target=\"_blank\">JSON</a>, and\nerrors are reported via standard HTTP codes\
    \ in addition to JSON-formatted\nerror information in the HTTP response bodies\
    \ of relevant requests. We use\n<a href=\"https://tools.ietf.org/html/rfc6749\"\
    \ target=\"_blank\">OAuth 2</a>\nfor authentication and authorization.\n\n## Core\
    \ Concepts\nQuip integrates documents and messages into a single unit that we\
    \ call a\nthread. Most of the operations in the Quip Automation API operate on\n\
    threads. Threads can simply be a list of messages, i.e., a chat thread,\nor they\
    \ may have a document in addition to a list of messages.\nEach thread has a permanent\
    \ 11 character id and a similar 12 character URL\nsuffix that can be expired by\
    \ the user. Apps receiving URLs should convert\nthem to permanent ids using Get\
    \ Thread before being used.\n\nQuip documents are broken down into smaller units\
    \ we call sections. Every\nparagraph in a document is a separate section, as is\
    \ every item in a list\nor cell in a table. The Quip Automation API outputs documents\
    \ as HTML for\nconvenience, and the elements in the HTML have id attributes specifying\n\
    their internal section ID. When you want to perform advanced transforms\non a\
    \ document, like modifying a checklist, you will need to use the section\nIDs.\
    \ The official Python library contains a number of examples of parsing\nthe HTML\
    \ to get section IDs and using that data for edit operations.\n\nQuip folders\
    \ are not traditional file system folders. Quip folders are\nmore like tags, i.e.,\
    \ a thread can be in multiple folders. When a thread\nis in a folder, it inherits\
    \ the permissions of the folder, e.g., if you\nadd a thread to a folder shared\
    \ with three people, those three people will\nhave access to the thread. Each\
    \ user has special desktop and archive folders\nthat cannot be deleted, shared,\
    \ or renamed.\n\nA Quip thread can be shared with a list of folders and individual\
    \ users.\nA user can access the thread if they have access to any of the folders\n\
    or if they are individually added to the thread.\n\nWe refer to the people in\
    \ threads and folders as members throughout the API.\n\n# License Requirements\n\
    You can access Quip's APIs if your company uses any of these products:\n* A pre-existing\
    \ Quip for Customer 360 product\n* Quip Plus\n* Quip Advanced\n* Lightning Experience\
    \ in Enterprise, Professional, Performance, Unlimited,\nor Developer editions\n\
    \n<b>Note:</b> These Admin APIs are available only as add-on purchases:\n<a href=\"\
    https://quip.com/dev/admin/documentation/current#tag/Events-(requires-subscription)\"\
    >Events API </a>and\n<a href=\"https://quip.com/dev/admin/documentation/current#tag/Governance-(requires-subscription)\"\
    >Governance API</a>.\n\n# VPC Customers\nIf you're a <a href=\"https://help.salesforce.com/s/articleView?id=sf.quip_vpc.htm&amp;type=5\"\
    >Virtual Private Cloud </a>\n(VPC) customer, you can call Quip's APIs using URIs\
    \ in which you replace:\n<i>quip.com</i> with <i>customername.onquip.com</i>\n\
    or <i>quip-customername.com</i>.\n\nFor example, if your company is <b>Acme</b>\
    \ and the URI is\n<i>https://platform.quip.com/1/threads/edit-document</i>, as\
    \ a VPC\ncustomer, use one of these URIs instead depending on your company's\n\
    assigned VPC URL:\n\n* <i>https://platform.acme.onquip.com/1/threads/edit-document</i>\
    \ or\n* <i>https://platform.quip-acme.com/1/threads/edit-document</i>\n\n# Rate\
    \ Limits\nQuip's APIs have rate limits to help ensure fair and reliable access\
    \ to APIs\nfor all of our customers.\n\nWhen you call our APIs via integrations\
    \ you build (including integrations\nusing <a href=\"https://help.salesforce.com/s/articleView?id=sf.quip_actions_process.htm&type=5\"\
    \ntarget=\"_blank\">Process Builder</a> and\n<a href=\"https://help.salesforce.com/s/articleView?id=sf.quip_automation_flow.htm&type=5\"\
    \ntarget=\"_blank\">Flow</a>), those calls are subject to our rate limits.\n\n\
    ## Per-user Rate Limits\nThe Automation API is rate limited by number of requests\
    \ per minute per\nuser - with defaults of:\n\n* 50 requests per minute per user\n\
    * 750 requests per hour per user\n\nAPI responses include a few custom headers\
    \ to help developers implement\nbackoffs in their code. These headers are:\n\n\
    * `X-Ratelimit-Limit`: The number of requests per minute/hour the user can make\n\
    * `X-Ratelimit-Remaining`: The number of requests remaining this user can\nmake\
    \ within the minute/hour. This number changes with each request\n* `X-Ratelimit-Reset`:\
    \ The UTC timestamp for when the rate limit resets\n\n## Per-company Rate Limit\n\
    Quip's APIs are also subject to a per-company rate limit with a default of 600\n\
    requests per minute. The API responses include these custom headers to help\n\
    developers implement backoffs in their code:\n\n* `X-Company-RateLimit-Limit`:\
    \ The number of requests per minute that your company can make\n* `X-Company-RateLimit-Remaining`:\
    \ The number of requests remaining for your company within the minute\n* `X-Company-RateLimit-Reset`:\
    \ The UTC timestamp for when the rate limit resets\n* `X-Company-Retry-After`:\
    \ The number of seconds after which your company can make API calls again\n\n\
    ## Document Bulk Export Rate Limit\n[Create Bulk Export Request](#operation/createBulkExportRequest)\
    \ API\nis also subject to a per-company rate limit with a default of 36,000\n\
    documents exported per hour. The API responses include these custom headers to\
    \ help\ndevelopers implement backoffs in their code:\n\n* `X-Documentbulkexport-RateLimit-Limit`:\
    \ The number of documents per hour that your company can export\n* `X-Documentbulkexport-RateLimit-Remaining`:\
    \ The number of documents remaining for your company within the hour\n* `X-Documentbulkexport-RateLimit-Reset`:\
    \ The UTC timestamp for when the rate limit resets\n* `X-Documentbulkexport-Retry-After`:\
    \ The number of seconds after which your company can make API calls again\n\n\
    For example, `X-Documentbulkexport-RateLimit-Remaining` is 1000, if the\nnumber\
    \ of documents to be exported in the next request is `<=` 1000, this\nrequest\
    \ will succeed; if the number of documents to be exported in the next\nrequest\
    \ is `>` 1000, the request will fail and the subsequent requests will\nfail too\
    \ until the rate limit resets at\n`X-Documentbulkexport-RateLimit-Reset`.\n\n\
    # FAQs\n\n## Quip Developer FAQ\n\n### Which API should I use, the Automation\
    \ API or the Admin API?\nWe recommend that you use the\n[Automation API](https://quip.com/dev/automation/documentation/current)\n\
    to automate user-level processes such as document\n[copying](https://quip.com/dev/automation/documentation/current#operation/copyDocument)\n\
    and [editing](https://quip.com/dev/automation/documentation/current#operation/editDocument)\n\
    and to integrate Quip with your other systems. Use the\n[Admin API](https://quip.com/dev/admin/documentation/current)\
    \ for\nadmin-level site-wide or security workflows such as\n[activity monitoring](https://quip.com/dev/admin/documentation/current#tag/Events)\n\
    or [quarantining documents](https://quip.com/dev/admin/documentation/current#tag/Quarantine).\n\
    \n### Which systems can integrate with Quip's APIs?\nQuip's APIs integrate with\
    \ Salesforce, Slack, Google Workspace, Github,\nJira, Stripe, Dropbox, Box, Zendesk\
    \ and more. You can connect nearly any\napplication to Quip [using our APIs](https://quip.com/dev),\
    \ including\nyour company's proprietary applications or systems. Browse our\n\
    [sample apps](https://github.com/quip/quip-api/tree/master/samples) or\ndownload\
    \ prebuilt apps on\n[Salesforce AppExchange](https://appexchange.salesforce.com/appxSearchKeywordResults?keywords=quip&searchType=simpleSearch).\n\
    \n### Can I create a non-human user account for my integrations?\nIn the Quip\
    \ Admin Console,\n[create a placeholder user (not associated with an employee)\
    \ or bot user](https://help.salesforce.com/s/articleView?id=000356418&type=1)\n\
    for your integrations. That way, when you deprovision an employee's\nuser account,\
    \ the integration isn't affected. Additionally, this allows\nfor a more clear\
    \ separation of duties between an employee and an\nintegration user.\n\n### Is\
    \ there a way for the API keys to be rotated every 90 days automatically or would\
    \ this be a manual action?\nCurrently, there's no way for the API keys to change\
    \ automatically. You can only\n[create API keys](#section/Authentication/Get-Access-to-Quip's-APIs)\n\
    manually.\n\n### Which API calls are included in rate limits?\nAll of your company's\
    \ Admin and Automation API calls are counted in your\nrate limits, including calls\
    \ you make via\n[Process Builder](https://help.salesforce.com/s/articleView?id=sf.quip_actions_process.htm&type=5)\n\
    and\n[Flow](https://help.salesforce.com/s/articleView?id=sf.quip_automation_flow.htm&type=5).\n\
    There are per-user and per-company rate limits for the\n[Admin](https://quip.com/dev/admin/documentation/current#section/Rate-Limits)\n\
    and\n[Automation](https://quip.com/dev/automation/documentation/current#section/Rate-Limits)\
    \ APIs.\n\n### Can we raise our rate limits?\nIf you need to call APIs more frequently\
    \ than allowed by the\n[Admin](https://quip.com/dev/admin/documentation/current#section/Rate-Limits)\n\
    and\n[Automation](https://quip.com/dev/automation/documentation/current#section/Rate-Limits)\n\
    API rate limits, contact Quip Customer Support for help.\n\n### How do we monitor\
    \ our API usage?\nThe responses in Quip's [Admin](https://quip.com/dev/admin/documentation/current#section/Rate-Limits)\n\
    and\n[Automation](https://quip.com/dev/automation/documentation/current#section/Rate-Limits)\n\
    APIs contain headers that provide information about your API usage.\n\n### Is\
    \ there an API that can run reports on Quip engagement?\nUse the\n[Events API](https://quip.com/dev/admin/documentation/current#tag/Events)\n\
    to get information about Quip engagement. You can then feed that\ninformation\
    \ into your engagement monitoring systems.\n\n### What tools are available for\
    \ Quip eDiscovery and eArchiving?\nConsult our trusted partner for eDiscovery\
    \ and eArchiving solutions at\n[onna.com/quip](http://onna.com/quip).\n\n### How\
    \ do I export my Quip data?\nYou can export Quip documents or spreadsheets to\
    \ PDF using the\n[Create Export PDF Request](https://quip.com/dev/automation/documentation/current#operation/createExportThreadToPdfRequest)\n\
    API method.\n\n### How do I export comments from a Quip document?\nUse the\n[Get\
    \ Recent Messages](https://quip.com/dev/automation/documentation/current#operation/getRecentMessages)\n\
    API method to retrieve the 25 most-recent comments in a Quip document.\nYou can\
    \ then export the response of your API call to your other systems.\n\n### How\
    \ do we deprovision users?\nThe Disable User\n[v1.1](https://quip.com/dev/scim/documentation#disable-user-v1-1)\
    \ or\n[v2.0](https://quip.com/dev/scim/documentation#disable-user-v2) API method\n\
    allows you to deactivate a user account.\n\n### Can we subscribe to news about\
    \ changes to API documentation or feature updates?\nRead the\n[release notes](https://admin.salesforce.com/release-resources)\
    \ to find out\nabout new Quip developer features. Subscribe to the\n[Salesforce\
    \ Developer newsletter](https://developer.salesforce.com/newsletter)\nto get developer\
    \ news, tips, and best practices. You can also follow these\nsocial media channels:\n\
    [SalesforceDevs Twitter feed](https://twitter.com/SalesforceDevs),\n[SalesforceDevs\
    \ LinkedIn page](https://www.linkedin.com/showcase/salesforce-developers),\n[SalesforceDevs\
    \ Facebook page](https://www.facebook.com/salesforcedevs).\n\n### More questions?\n\
    Ask other Quip developers on\n[Salesforce Stack Exchange](https://salesforce.stackexchange.com/search?q=quip).\n\
    \n\n## REST API Versioning FAQ\n\n### Why do API methods get versioned?\nTo improve\
    \ the quality and performance of API methods, Quip periodically\nreleases new\
    \ versions and deprecates older versions. Examples of changes\nthat sometimes\
    \ require creating new versions are:\n\n* Renaming an API method; or\n* Adding\
    \ a required input field; or\n* Removing or renaming an input field; or\n* Removing\
    \ an output field.\n\n### How do I know which version of an API method I'm using?\n\
    Versions are identified in the path for each API method. Examples:\n* <b>Version\
    \ 1</b>: GET https://platform.quip.com/1/admin/sampleresource.\n* <b>Version 2</b>:\
    \ GET https://platform.quip.com/2/admin/sampleresource.\n\n### How will I know\
    \ when an API method is deprecated?\nWe inform you in a release note at least\
    \ one year before support for an\nAPI method ends. In addition, we update the\
    \ reference documentation to\nidentify the current and deprecated versions of\
    \ an API method. Our REST APIs\nhave two versions of reference documentation:\n\
    * <b>Current</b>: Describes the functionality available only in the current\n\
    \  versions of methods in a REST API.\n* <b>All</b>: Describes the functionality\
    \ available in both current and\n  deprecated versions of methods in a REST API.\n\
    \n### What should I do when an API method is deprecated?\nUpdate your integrations\
    \ so that they point to the current version instead\nof a deprecated version before\
    \ support for an API method ends. Example\nscenario:\n* You have an integration\
    \ that points to version 1 of an API method at this\n  path: GET https://platform.quip.com/1/admin/sampleresource\n\
    * Version 2 of the API method is introduced and version 1 is deprecated.\n* Before\
    \ support for version 1 ends, you must update your integration to\n  point to\
    \ version 2 of the API method at this path: GET\n  https://platform.quip.com/2/admin/sampleresource.\n\
    \nAs needed, for your integrations, you can download the\n[OpenAPI Specification\
    \ (OAS) files](/dev/admin/documentation/current/openapi-info)\nfor current and\
    \ all versions of each REST API.\n"
servers:
- url: https://platform.quip.com
tags:
- name: Authentication
  description: "\n## Overview\n\nAuthentication gives you access to the Quip Admin\
    \ and Automation APIs.\nYou can build integrations that call our APIs. To access\
    \ Quip's APIs,\nfirst\n[create an API key](https://help.salesforce.com/s/articleView?id=sf.anywhere_new_api_key.htm&type=5).\n\
    Then get an access token using the API key as described in\n[Get Access to Quip's\
    \ APIs](#section/Authentication/Get-Access-to-Quip's-APIs).\nYou can create additional\
    \ API keys for your other integrations\nwith the applicable scopes needed for\
    \ the features in a specific\nintegration. You can also get a\n[personal access\
    \ token](https://quip.com/dev/token)\nto test our APIs.\n\n<SecurityDefinitions\
    \ />\nNote: Before building applications, you must select your required scopes\n\
    when you create the\n[API keys](https://help.salesforce.com/s/articleView?id=sf.anywhere_new_api_key.htm&type=5).\n\
    And ensure that your application users have the correct access to the\ncontent\
    \ they'll use in your applications. For example, if users need to\nedit a Quip\
    \ document using your application, they must have edit access\non that document.\n\
    \n## Best Practices\n\nHere are some recommended practices to follow to protect\
    \ your Quip data and improve your user experience:\n\n* Limit the scopes in your\
    \ API keys to the ones needed for the features\n  in your integrations. For example,\
    \ if you create an application whose\n  users edit but don't manage content, don't\
    \ include the `USER_MANAGE`\n  scope in the API key for that application.\n* Tokens\
    \ expire every 30 days. Use the\n  [Token Endpoint](https://quip.com/dev/automation/documentation/current#operation/accessToken)\n\
    \  to refresh your tokens before their expiration. That way your users\n  have\
    \ uninterrupted access to your integrations.\n* Use\n  [Verify Token](https://quip.com/dev/automation/documentation/current#operation/verifyToken)\n\
    \  to see if a token is expired or revoked and find out which scopes\n  apply\
    \ to the token.\n* [Revoke](https://quip.com/dev/automation/documentation/current#operation/revokeToken)\n\
    \  tokens for integrations that you're no longer using. Deleting\n  a token in\
    \ Postman (or your other chosen tool) doesn't revoke access.\n  You can use the\
    \ Admin Console to revoke an API key that you're no longer\n  using (under Settings\
    \ > Integrations > Action menu > Revoke).\n\n## Get Access to Quip's APIs\n\n\
    <br/>\n\n### Personal Authentication Process\n\nYou can generate an access token\
    \ that provides API access to your own,\npersonal Quip account. This is useful\
    \ for testing the API, automating tasks,\nor integrating with other services you\
    \ use individually.\n\nTo generate a personal access token, visit this page:\n\
    <a href=\"https://quip.com/dev/token\" target=\"_blank\">https://quip.com/dev/token</a>\n\
    \nWhenever you generate a new token, all previous tokens are automatically invalidated.\n\
    \nOnce you have a token, the easiest way to use it is via the\n<a href=\"https://github.com/quip/quip-api\"\
    \ target=\"_blank\">Python Client Library</a>,\nwhich makes most tasks a single\
    \ line of code. All of the\ndocumentation below contains copy-and-paste Python\
    \ code snippets to make\nit easier to get started.\n\n<br/>\n\n### OAuth Process\n\
    \n<br/>\n\n#### Prerequisites\n\nTo access to the Quip Admin and Automation APIs:\n\
    * You must be an admin to create an API key.\n* In addition, for access to the\
    \ <b>Admin</b> API, your admin has to add\n  you to the Admin API Users list in\
    \ the Admin Console\n  (under <b>Settings > Site Settings</b>).\n\n<b>Note:</b>\
    \ These Admin APIs are available only as add-on purchases:\n[Events API](https://quip.com/dev/admin/documentation/current#tag/Events)\n\
    and\n[Governance API](https://quip.com/dev/admin/documentation/current#tag/Governance-(requires-subscription)).\n\
    \n#### Process Overview\n\nTo get access to the Quip Admin and Automation APIs,\
    \ follow the process\nsummarized in the diagram below. The process is described\
    \ in detail in\nthe Generate an OAuth Token section.\n\n<img src=\"https://quip-cdn.com/9rh5koDSTP6K0frp45qMFQ\"\
    /><br/>\n\n#### Generate an OAuth Token\n\n<br/>\n\n<b>1. Create an API Key</b>\n\
    \na. In the Quip Admin Console\n[create an API key](https://help.salesforce.com/s/articleView?id=sf.anywhere_new_api_key.htm&type=5)\n\
    and select the scopes that you need for the features in your integration.\n\n\
    b. Copy the client ID and client secret so you can use them to get an access token.\n\
    \n<img src=\"https://quip-cdn.com/SGzZDKk_tZgCDdPeu5eQlQ\"/>\n\nNote:\n* You can\
    \ create additional API keys for your integrations with only the\n  applicable\
    \ scopes needed for the features in the integrations.\n* You can create a maximum\
    \ of 100 API keys for your company. We suggest\n  that you keep this limit in\
    \ mind when you create API keys for your\n  integrations. You can see all the\
    \ API keys your company has in the\n  Quip Admin Console under <b>Settings > Integrations</b>.\n\
    \n<br/>\n\n<b>2. Get an Access Token</b>\n\nUse your preferred tool such as\n\
    [Postman](https://www.postman.com)\nor\n[SoapUI](https://www.soapui.org)\nto get\
    \ an access token. This example uses Postman:\n\na. [Create a request in Postman](https://learning.postman.com/docs/sending-requests/requests/#creating-requests).\n\
    \nb. Click the Authorization tab.\n\nc. From the Type dropdown list, select Oauth\
    \ 2.0.\n\n<img src=\"https://quip-cdn.com/voVgHjxWR0veKJtDwOu0DQ\"/>\n\nd. In\
    \ the <b>Configure New Token</b> section, fill in the fields as described here:\n\
    * <b>Token Name</b>: Give the token a short, descriptive name. When\n  you create\
    \ additional tokens for your integrations, use a name that\n  easily identifies\
    \ the integration.\n* <b>Callback URL</b>: `https://platform.quip.com`\n* <b>Authorize\
    \ using browser</b>: Leave the box unchecked.\n* <b>Auth URL</b>: `https://platform.quip.com/1/oauth/login`\n\
    \  If you're a\n  [Virtual Private Cloud](https://help.salesforce.com/s/articleView?id=sf.quip_vpc.htm&type=5)\n\
    \  (VPC) customer, use one of these URLs instead, depending on your\n  company's\
    \ assigned VPC URL:\n  * `https://platform.<customername>.onquip.com/1/oauth/login`\n\
    \  or\n  * `https://platform.quip-<customername>.com/1/oauth/login`\n* <b>Access\
    \ Token URL</b>: `https://platform.quip.com/1/oauth/access_token`\n  If you're\
    \ a VPC customer, use one of these URLs instead, depending\n  on your company's\
    \ assigned VPC URL:\n  * `https://platform.<customername>.onquip.com/1/oauth/access_token`\n\
    \  or\n  * `https://platform.quip-<customername>.com/1/oauth/access_token`\n*\
    \ <b>Client ID</b> and <b>Client Secret</b>: Use the values that you\n  copied\
    \ from the API key in the Quip Admin Console.\n* <b>Scope</b> and <b>State</b>:\
    \ Leave blank.\n* <b>Client Authentication</b>: Select Send client credentials\
    \ in body.\n\ne. Click <b>Get New Access Token</b>.\n\n<img src=\"https://quip-cdn.com/Fy43SToP5WvsYNyRDuvFYA\"\
    /><br/><br/>\n\n<b>3. Get authorization from Quip</b>\n\nWhen prompted, use your\
    \ admin email address and password to log into\nyour Quip site and get an authorization\
    \ token. This is required only\nthe first time you get an access token.\n\n<img\
    \ src=\"https://quip-cdn.com/mpQMhtFbpjrHOmocpz17GQ\"/><br/><br/>\n\n<b>4. Save\
    \ the Token</b>\n\nIn Postman, the token details are displayed. Click Use Token\
    \ to\nsave the provided token in your request and use it in your next\nAPI call.\n\
    \n<img src=\"https://quip-cdn.com/URJ2kLTJA7xElfJiw_vfSQ\"/>\n\nCongratulations!\
    \ You can now make Admin and Automation API calls.\nFollow these same instructions\
    \ to get additional access tokens using\nAPI keys with the scopes required for\
    \ the integrations you're building.\n\n<b>Note:</b> Tokens expire every 30 days.\
    \ Use the\n[Token Endpoint](https://quip.com/dev/automation/documentation/current#operation/accessToken)\n\
    to refresh your tokens before the 30-day expiration. That way your users\nhave\
    \ uninterrupted access to your integrations.\n\n## Next Steps\n\nNow that you\
    \ have access to our APIs, you can start building your\nintegrations with Quip:\n\
    * Browse through the reference documentation to see what you can build\n  with\
    \ our APIs.\n* Download our\n  [OpenAPI Specification (OAS) files](https://quip.com/dev/admin/documentation/current/openapi-info)\n\
    \  to build your integrations.\n* Check out our\n  [sample apps](https://github.com/quip/quip-api/tree/master/samples).\n\
    * Use a token associated with an API key together with domain\n  authentication\
    \ to build applications that integrate with Quip.\n\nQuestions? Ask the Quip developer\
    \ community on\n[Salesforce Stack Exchange](https://salesforce.stackexchange.com/questions/tagged/quip).\n\
    \n## Domain Authentication\nDomain authentication is only available for Quip Enterprise\
    \ administrators.\nTo enable this for your company, <a href=\"mailto:sales@quip.com\"\
    >contact us</a>.\n\nDomain authentication enables seamless integration for internal\
    \ or\npre-approved services at your company. Domain authentication is simply\n\
    <a href=\"https://tools.ietf.org/html/rfc6749\" target=\"_blank\">OAuth 2.0</a>,\n\
    but instead of end users individually approving access to each application,\n\
    domain administrators pre-approve applications, and end users do not see\nadditional\
    \ authorization prompts during the OAuth authorization process.\n\nTo enable domain\
    \ authentication for a third-party application:\n\n1. Create an OAuth 2.0 token\
    \ for the application you want to integrate. You\nwill typically create a separate\
    \ token for each app you want to integrate\nand name it after the app, which enables\
    \ easy revocation when your company\nis no longer using the service.\n2. Configure\
    \ the application with the OAuth 2.0 authorization endpoint\n`/oauth/login` and\
    \ the OAuth 2.0 token endpoint `/oauth/access_token`.\n3. When a member of your\
    \ company uses the application to access Quip, the\nauthorization redirects will\
    \ happen automatically and will not ask for any\nadditional approval.\n"
- name: Use cases
  description: "## Edit a Document Use Cases\n\nThis document provides sample calls\
    \ for some common use cases for the Edit\na Document API method. In the examples\
    \ below, we use the HTML format for\nthe document content. You can mix and match\
    \ the examples based on your\nbusiness needs. See the [Edit a Document](#operation/editDocument)\n\
    reference documentation for more details including a sample response and\ninformation\
    \ about the `section_id`, `location`, `data-live-app-id`, and\n`document_range`\
    \ fields.\n\n**Note:** If you're a [Virtual Private\nCloud](https://help.salesforce.com/s/articleView?id=sf.quip_vpc.htm&type=5)\n\
    (VPC) customer, see the Access Rules for more information about URIs to\nuse for\
    \ your API calls.\n\n### Add an Item at the End of a List\nIn this example, the\
    \ `section_id` belongs to an item at the end (location\n**2**) of a bulleted or\
    \ numbered list or checklist.\n\n```text\nPOST https://platform.quip.com/1/threads/edit-document\n\
    Content-Type: application/json\nAuthorization: Bearer ABCSampleAccessToken\n\n\
    {\n    \"thread_id\": \"vTYlBwL8UT85\",\n    \"format\": \"html\",\n    \"content\"\
    : \"<li>Expert recommendations</li>\",\n    \"section_id\": \"HcDACAX1iOK\",\n\
    \    \"location\": 2\n}\n```\n\nHere's how the list looks before and after the\
    \ API call:\n\n<table>\n  <tr>\n    <th>Before the call</th>\n    <th>After the\
    \ call</th>\n  </tr>\n  <tr>\n    <td>\n      <ul>\n        <li>Customer feedback</li>\n\
    \        <li>Usage metrics</li>\n      </ul>\n    </td>\n    <td>\n        <li>Customer\
    \ feedback</li>\n        <li>Usage metrics</li>\n        <li>Expert recommendations</li>\n\
    \    </td>\n  </tr>\n</table>\n\n### Add a Paragraph before Other Content\n\n\
    In this example, `the section_id` belongs to a paragraph before (location\n**3**)\
    \ which another paragraph is added.\n\n```text\nPOST https://platform.quip.com/1/threads/edit-document\n\
    Content-Type: application/json\nAuthorization: Bearer ABCSampleAccessToken\n\n\
    {\n    \"thread_id\": \"XerkArZUfekP\",\n    \"format\": \"html\",\n    \"content\"\
    : \"<p>Here's the account information for Acme Company:</p>\",\n    \"section_id\"\
    : \"HcDACAwByNQ\",\n    \"location\": 3\n}\n```\n\nHere's how the paragraph looks\
    \ before and after the API call:\n\n<table>\n  <tr>\n    <th>Before the call</th>\n\
    \    <th>After the call</th>\n  </tr>\n  <tr>\n    <td>\n      <p>This customer\
    \ is on the west coast.</p>\n    </td>\n    <td>\n      <p>Here's the account\
    \ information for Acme Company:</p>\n      <p>This customer is on the west coast.</p>\n\
    \    </td>\n  </tr>\n</table>\n\n\n### Add Multiple Paragraphs after Other Content\n\
    \nIn this example, the `section_id` belongs to a paragraph after (location\n**2**)\
    \ which multiple paragraphs are added.\n\n```text\nPOST https://platform.quip.com/1/threads/edit-document\n\
    Content-Type: application/json\nAuthorization: Bearer ABCSampleAccessToken\n\n\
    {\n    \"thread_id\": \"vTYlBwL8UT85\",\n    \"format\": \"html\",\n    \"content\"\
    : \"<p>Customers like Acme want more options.</p><p>They like personalized service.</p>\"\
    ,\n    \"section_id\": \"HcDACAJZEQf\",\n    \"location\": 2\n}\n```\n\nHere's\
    \ how the content looks before and after the API call:\n\n<table>\n  <tr>\n  \
    \  <th>Before the call</th>\n    <th>After the call</th>\n  </tr>\n  <tr>\n  \
    \  <td>\n      <p>Here's the account information for Acme Company:</p>\n     \
    \ <p>This customer is on the west coast.</p>\n    </td>\n    <td>\n      <p>Here's\
    \ the account information for Acme Company:</p>\n      <p>This customer is on\
    \ the west coast.</p>\n      <p>Customers like Acme want more options.</p>\n \
    \     <p>They like personalized service.</p>\n    </td>\n  </tr>\n</table>\n\n\
    ### Edit a Paragraph/Replace Content\n\nIn this example, the `section_id` belongs\
    \ to the paragraph that's\nedited/replaced (location **4**). You can  edit/replace\
    \ a document range\ninstead, by passing **8** into the location field. See the\
    \ [Edit a\nDocument](#operation/editDocument) reference documentation for more\n\
    information about the `document_range` field.\n\n```text\nPOST https://platform.quip.com/1/threads/edit-document\n\
    Content-Type: application/json\nAuthorization: Bearer ABCSampleAccessToken\n\n\
    {\n    \"thread_id\": \"vTYlBwL8UT85\",\n    \"format\": \"html\",\n    \"content\"\
    : \"<p>Customers like Acme want more choices. They want a buffet experience.</p>\"\
    ,\n    \"section_id\": \"HcDABAJZEQf\",\n    \"location\": 4\n}\n```\n\nHere's\
    \ how the paragraph looks before and after the API call:\n\n<table>\n  <tr>\n\
    \    <th>Before the call</th>\n    <th>After the call</th>\n  </tr>\n  <tr>\n\
    \    <td>\n      <p>Customers like Acme want more options.</p>\n    </td>\n  \
    \  <td>\n      <p>Customers like Acme want more choices. They want a buffet experience.</p>\n\
    \    </td>\n  </tr>\n</table>\n\n### Delete a Document Range\n\nIn this example,\
    \ the `document_range` belongs to the content (heading title\n**Topic 2 - Prerequisites**\
    \ and content under that heading and its\nsubheadings) that's deleted (location\
    \ **9**).\n\n```text\nPOST https://platform.quip.com/1/threads/edit-document\n\
    Content-Type: application/json\nAuthorization: Bearer ABCSampleAccessToken\n\n\
    {\n    \"thread_id\": \"vTYlBwL8UT85\",\n    \"location\": 9,\n    \"document_range\"\
    : \"Topic 2  - Prerequisites\"\n}\n```\n\nHere's how the content looks before\
    \ and after the API call:\n\n<table>\n  <tr>\n    <th>Before the call</th>\n \
    \   <th>After the call</th>\n  </tr>\n  <tr>\n    <td>\n      <h4>Topic 1 - Introduction</h4>\n\
    \      <p>Content under Topic 1.</p>\n      <h4>Topic 2 - Prerequisites</h4>\n\
    \      <p>Content under Topic 2.</p>\n      <h5>Subtopic 2.1</h5>\n      <p>Content\
    \ under Subtopic 2.1.</p>\n      <h6>Subtopic 2.1.1</h6>\n      <p>Content under\
    \ Subtopic 2.1.1.</p>\n      <h4>Topic 3 - Acceptance Criteria</h4>\n      <p>Content\
    \ under Topic 3.</p>\n    </td>\n    <td>\n      <h4>Topic 1 - Introduction</h4>\n\
    \      <p>Content under Topic 1.</p>\n      <h4>Topic 3 - Acceptance Criteria</h4>\n\
    \      <p>Content under Topic 3.</p>\n    </td>\n  </tr>\n</table>\n\n\n### Add,\
    \ Edit, or Replace Content in or Around a Document Range\n\nIn this example, the\
    \ `document_range` belongs to the content (heading title\n**Topic 4 - Important\
    \ Notes** and content under that heading and its\nsubheadings) that's edited/replaced\
    \ (location **8**). You can add content\nbefore or after a document range by passing\
    \ **7** (before) or **6** (after) into\nthe `location` field. See the [Edit a\n\
    Document](#operation/editDocument) reference documentation for\nmore information\
    \ about the `document_range` field.\n\n```text\nPOST https://platform.quip.com/1/threads/edit-document\n\
    Content-Type: application/json\nAuthorization: Bearer ABCSampleAccessToken\n\n\
    {\n    \"thread_id\": \"vTYlBwL8UT85\",\n    \"content\": \"<h2>Topic 4 - Considerations</h2><p>Our\
    \ beta launch requires training users who speak multiple languages.</p>\",\n \
    \   \"location\": 8,\n    \"document_range\": \"Topic 4 - Important Notes\"\n\
    }\n```\n\nHere's how the content looks before and after the API call:\n\n<table>\n\
    \  <tr>\n    <th>Before the call</th>\n    <th>After the call</th>\n  </tr>\n\
    \  <tr>\n    <td>\n      <h4>Topic 4 - Important Notes</h4>\n      <p>Our beta\
    \ launch requires user training.<p>\n    </td>\n    <td>\n      <h4>Topic 4 -\
    \ Considerations</h4>\n      <p>Our beta launch requires training users who speak\
    \ multiple languages.</p>\n    </td>\n  </tr>\n</table>\n\n### Add a Row to a\
    \ Spreadsheet\n\nIn this example, the `section_id` belongs to the row after (location\
    \ **2**)\nwhich another row is added.\n\n```text\nPOST https://platform.quip.com/1/threads/edit-document\n\
    Content-Type: application/json\nAuthorization: Bearer ABCSampleAccessToken\n\n\
    {\n    \"thread_id\": \"vTYlBwL8UT85\",\n    \"format\": \"html\",\n    \"content\"\
    : \"<tr><td>7</td><td>4,581</td><td>570</td></tr>\",\n    \"section_id\": \"temp:C:dabc38cb2d6f789b426a14f31946\"\
    ,\n    \"location\": 2\n}\n```\n\nHere's how the spreadsheet looks before and\
    \ after the API call:\n\n<table>\n  <tr>\n    <th>Before the call</th>\n    <th>After\
    \ the call</th>\n  </tr>\n  <tr>\n    <td>\n      <table>\n        <tr>\n    \
    \      <th colspan=\"3\">Social media page likes in the past 3 months.</th>\n\
    \        </tr>\n        <tr>\n          <td>83</td>\n          <td>75,914</td>\n\
    \          <td>35608</td>\n        </tr>\n        <tr>\n          <td>94</td>\n\
    \          <td>2560</td>\n          <td>32569</td>\n        </tr>\n        <tr>\n\
    \          <td>10</td>\n          <td>93387</td>\n          <td>9358</td>\n  \
    \      </tr>\n      </table>\n    </td>\n    <td>\n      <table>\n        <tr>\n\
    \          <th colspan=\"3\">Social media page likes in the past 3 months.</th>\n\
    \        </tr>\n        <tr>\n          <td>83</td>\n          <td>75,914</td>\n\
    \          <td>35608</td>\n        </tr>\n        <tr>\n          <td>94</td>\n\
    \          <td>2560</td>\n          <td>32569</td>\n        </tr>\n        <tr>\n\
    \          <td>7</td>\n          <td>4,581</td>\n          <td>570</td>\n    \
    \    </tr>\n        <tr>\n          <td>10</td>\n          <td>93387</td>\n  \
    \        <td>9358</td>\n        </tr>\n      </table>\n    </td>\n  </tr>\n</table>\n\
    \n### Edit a Cell in a Spreadsheet\n\nIn this example, the `section_id` belongs\
    \ to the cell that's edited/replaced\n(location **4**).\n\n```text\nPOST https://platform.quip.com/1/threads/edit-document\n\
    Content-Type: application/json\nAuthorization: Bearer ABCSampleAccessToken\n\n\
    {\n    \"thread_id\": \"vTYlBwL8UT85\",\n    \"format\": \"html\",\n    \"content\"\
    : \"98\",\n    \"section_id\": \"temp:s:HcDACAFj25V_temp:C:HcD5aa735cfd0dd58e3eee0e5ef0\"\
    ,\n    \"location\": 4\n}\n```\n\nThe table below shows how the spreadsheet looks\
    \ before and after the API\ncall. In this example, the first cell in the spreadsheet\
    \ is edited:\n\n<table>\n  <tr>\n    <th>Before the call</th>\n    <th>After the\
    \ call</th>\n  </tr>\n  <tr>\n    <td>\n      <table>\n        <tr>\n        \
    \  <th colspan=\"3\">Social media page likes in the past 3 months.</th>\n    \
    \    </tr>\n        <tr>\n          <td>83</td>\n          <td>75,914</td>\n \
    \         <td>35608</td>\n        </tr>\n        <tr>\n          <td>94</td>\n\
    \          <td>2560</td>\n          <td>32569</td>\n        </tr>\n        <tr>\n\
    \          <td>7</td>\n          <td>4,581</td>\n          <td>570</td>\n    \
    \    </tr>\n        <tr>\n          <td>10</td>\n          <td>93387</td>\n  \
    \        <td>9358</td>\n        </tr>\n      </table>\n    </td>\n    <td>\n \
    \     <table>\n        <tr>\n          <th colspan=\"3\">Social media page likes\
    \ in the past 3 months.</th>\n        </tr>\n        <tr>\n          <td>98</td>\n\
    \          <td>75,914</td>\n          <td>35608</td>\n        </tr>\n        <tr>\n\
    \          <td>94</td>\n          <td>2560</td>\n          <td>32569</td>\n  \
    \      </tr>\n        <tr>\n          <td>7</td>\n          <td>4,581</td>\n \
    \         <td>570</td>\n        </tr>\n        <tr>\n          <td>10</td>\n \
    \         <td>93387</td>\n          <td>9358</td>\n        </tr>\n      </table>\n\
    \    </td>\n  </tr>\n</table>\n\n### Add a Live App after Other Content\n\nThe\
    \ `data-live-app-id` mentioned in the `content` field applies to the type of\n\
    live app that's added. In this example, the live app is a calendar and the\n`section_id`\
    \ belongs to a paragraph after (location **2**) which the calendar is\nadded.\
    \ This scenario adds a calendar containing two events scheduled for 4\nOctober\
    \ 2021 and 18 October 2021.\n\n```text\nPOST https://platform.quip.com/1/threads/edit-document\n\
    Content-Type: application/json\nAuthorization: Bearer ABCSampleAccessToken\n\n\
    {\n    \"thread_id\": \"vTYlBwL8UT85\",\n    \"format\": \"html\",\n    \"content\"\
    : \"<div data-live-app-id='AbNBjAC13no' \\\n                  data-live-app-payload='{\\\
    \n                    \\\"events\\\":[\\\n                      {\\\n        \
    \                \\\"color\\\":\\\"GREEN\\\",\\\n                        \\\"\
    dateRange\\\":{\\\"start\\\":\\\"2021-10-04\\\",\\\"end\\\":\\\"2021-10-04\\\"\
    },\\\n                        \\\"content\\\":\\\"Kickoff Meeting\\\"\\\n    \
    \                  },\\\n                      {\\\n                        \\\
    \"color\\\":\\\"RED\\\",\\\n                        \\\"dateRange\\\":{\\\"start\\\
    \":\\\"2021-10-18\\\",\\\"end\\\":\\\"2021-10-18\\\"},\\\n                   \
    \     \\\"content\\\":\\\"Project Status\\\"\\\n                      }],\\\n\
    \                   \\\"displayMonth\\\":\\\"2021-10\\\"\\\n                 \
    \ }'>\\\n                </div>\",\n    \"section_id\": \"HcDACAxeuYo\",\n   \
    \ \"location\": 2\n}\n```\n\nHere's how the content looks before and after the\
    \ API call:\n\n<table>\n  <tr>\n    <th>Before the call</th>\n    <th>After the\
    \ call</th>\n  </tr>\n  <tr>\n    <td>\n      <p>Let's start a customer satisfaction\
    \ project.<p>\n    </td>\n    <td>\n      <img src=\"https://quip-cdn.com/cmwWoZbqu_JxcaX7If51ng\"\
    />\n    </td>\n  </tr>\n</table>\n\n\n### Edit Content in a Live App\n\nIn this\
    \ example, the `section_id` belongs to the cell in the live app that's\nedited/replaced\
    \ (location **4**). This scenario replaces the name of the\ncalendar event \"\
    Kickoff Meeting\" with \"Project Kickoff\".\n\n```text\nPOST https://platform.quip.com/1/threads/edit-document\n\
    Content-Type: application/json\nAuthorization: Bearer ABCSampleAccessToken\n\n\
    {\n    \"thread_id\": \"vTYlBwL8UT85\",\n    \"format\": \"html\",\n    \"content\"\
    : \"Project Kickoff\",\n    \"section_id\": \"temp:C:HcDe5a29801dd43ce5b7d68c43f3\"\
    ,\n    \"location\": 4\n}\n```\n\nHere's how the content looks before and after\
    \ the API call:\n\n<table>\n  <tr>\n    <th>Before the call</th>\n    <th>After\
    \ the call</th>\n  </tr>\n  <tr>\n    <td>\n      <img src=\"https://quip-cdn.com/cmwWoZbqu_JxcaX7If51ng\"\
    />\n    </td>\n    <td>\n      <img src=\"https://quip-cdn.com/hmtnjA5h1QZlQoXuiORJPg\"\
    />\n    </td>\n  </tr>\n</table>\n\n### Summary of Additional Use Cases for Adding\
    \ Live Apps\n\n[comment]: <> (I did not find a way to include a codeblock into\
    \ a table)\n[comment]: <> (nicely. Omitting the closing </td> sorta kinda works.)\n\
    \n<table>\n  <tr>\n    <th>Live App Type</th>\n    <th>Summary of Use Case</th>\n\
    \    <th>Sample HTML for Content Field</th>\n  </tr>\n  <tr>\n    <th>Salesforce\
    \ Record</th>\n    <td>Add a Salesforce record</td>\n    <td>\n\n      <div data-live-app-id='XdJAjAN5Jbi'\
    \ data-live-app-payload='{\n        \"record_id\": \"0013h00000C9tHJAAZ\",\n \
    \       \"org_id\": \"00D3h000004XoQgEAK\" }'>\n      </div>\n\n  </tr>\n  <tr>\n\
    \    <th>Salesforce List</th>\n    <td>Add a Salesforce record list</td>\n   \
    \ <td>\n\n      <div data-live-app-id='QYUAjAGNxIo' data-live-app-payload='{\n\
    \        \"list_id\": \"00B3h000005lR7jEAE\",\n        \"object_type\": \"Account\"\
    ,\n        \"org_id\": \"00D3h000004XoQgEAK\" }'>\n      </div>\n\n  </tr>\n \
    \ <tr>\n    <th>Salesforce List</th>\n    <td>Add a Salesforce related list</td>\n\
    \    <td>\n\n      <div data-live-app-id='QYUAjAGNxIo' data-live-app-payload='{\n\
    \        \"record_id\": \"0013h00000Db6YAAAZ\",\n        \"related_list_type\"\
    : \"Contact\",\n        \"org_id\": \"00D3h000004XoQgEAK\" }'>\n      </div>\n\
    \n  </tr>\n  <tr>\n    <th>Kanban Board</th>\n    <td>Add a Kanban board with\
    \ three columns:\n      <ul>\n        <li>To Do</li>\n        <li>In Progress</li>\n\
    \        <li>Completed</li>\n      </ul>\n    </td>\n    <td>\n\n      <div data-live-app-id='KORAjAYHE50'\
    \ data-live-app-payload='{\n        \"columns\": [\n            {\n          \
    \    \"color\": \"RED\",\n              \"headerContent\": \"To Do\",\n      \
    \        \"cards\": [\n                  {\n                    \"color\": \"\
    RED\",\n                    \"content\": \"First Card\"\n                  }\n\
    \              ]\n            },\n            {\n              \"color\": \"YELLOW\"\
    ,\n              \"headerContent\": \"In Progress\",\n              \"cards\"\
    : [\n                  {\n                    \"color\": \"YELLOW\",\n       \
    \             \"content\": \"Second Card\"\n                  },\n           \
    \       {\n                    \"color\": \"YELLOW\",\n                    \"\
    content\": \"New Card\"\n                  }\n              ]\n            },\n\
    \            {\n              \"color\": \"BLUE\",\n              \"headerContent\"\
    : \"Title\",\n              \"cards\": [\n                  {\n              \
    \      \"color\": \"BLUE\",\n                    \"content\": \"\"\n         \
    \         },\n                  {\n                    \"color\": \"BLUE\",\n\
    \                    \"content\": \"Third Card\"\n                  },\n     \
    \             {\n                    \"color\": \"BLUE\",\n                  \
    \  \"content\": \"New Card\"\n                  }\n              ]\n         \
    \   }\n        ] }'>\n      </div>\n\n  </tr>\n  <tr>\n    <th>Project Tracker</th>\n\
    \    <td>Add a project tracker with five columns::\n      <ul>\n        <li>Project</li>\n\
    \        <li>Owner</li>\n        <li>Status</li>\n        <li>Deadline</li>\n\
    \        <li>Attachment</li>\n      </ul>\n    </td>\n    <td>\n\n    <div data-live-app-id='JdGAjAc35Es'\
    \ data-live-app-payload='{\n      \"columns\": [\n          {\n            \"\
    content\": \"Project\\\\n\",\n            \"type\": \"TEXT\",\n            \"\
    id\": \"0\"\n          },\n          {\n            \"content\": \"Owner\\\\n\"\
    ,\n            \"type\": \"PERSON\",\n            \"id\": \"1\"\n          },\n\
    \          {\n            \"content\": \"Status\\\\n\",\n            \"type\"\
    : \"STATUS\",\n            \"id\": \"2\",\n            \"options\": [\n      \
    \          {\n                  \"label\": \"Upcoming\",\n                  \"\
    devName\": \"upcoming\",\n                  \"color\": \"BLUE\"\n            \
    \    },\n                {\n                  \"label\": \"In Progress\",\n  \
    \                \"devName\": \"in_progress\",\n                  \"color\": \"\
    YELLOW\"\n                },\n                {\n                  \"label\":\
    \ \"Complete\",\n                  \"devName\": \"complete\",\n              \
    \    \"color\": \"GREEN\"\n                }\n            ]\n          },\n  \
    \        {\n            \"content\": \"Deadline\\\\n\",\n            \"type\"\
    : \"DATE\",\n            \"id\": \"3\"\n          },\n          {\n          \
    \  \"content\": \"Attachment\\\\n\",\n            \"type\": \"FILE\",\n      \
    \      \"id\": \"4\"\n          }\n      ],\n      \"rows\": [\n          {\n\
    \            \"0\": \"Test\\\\n\",\n            \"1\": [\n                \"dFdAEAoma2c\"\
    \n            ],\n            \"2\": \"upcoming\",\n            \"3\": 1605686400000,\n\
    \            \"4\": null\n          },\n          {\n            \"0\": \"New\
    \ Project\\\\n\",\n            \"1\": [],\n            \"2\": null,\n        \
    \    \"3\": null,\n            \"4\": null\n          },\n          {\n      \
    \      \"0\": \"New Project\\\\n\",\n            \"1\": [],\n            \"2\"\
    : null,\n            \"3\": null,\n            \"4\": null\n          }\n    \
    \  ] }'>\n    </div>\n\n  </tr>\n</table>\n\n### See also\n\n[Edit a Document\
    \ reference documentation](https://quip.com/dev/automation/documentation/current#operation/editDocument)\n\
    \n[How Does Live Data Work in Quip?](https://help.salesforce.com/s/articleView?id=sf.live_data_quip.htm&type=5)\n\
    \n[Live Apps Developer Guide](https://quip.com/dev/liveapps/1.x.x/guide/)\n"
- name: Threads
- name: Messages
- name: Folders
- name: Users
- name: Realtime
components:
  securitySchemes:
    OAuth2:
      description: 'Use an

        [OAuth2](https://oauth.net/2/)-compatible

        mechanism for authentication. Quip''s approach

        follows [RFC 6749](https://datatracker.ietf.org/doc/html/rfc6749).


        Our API endpoints accept authentication tokens as described in

        [RFC 6750](https://datatracker.ietf.org/doc/html/rfc6750).

        In most cases, this means that when you call our API endpoints, you

        can pass in an `Authorization` header with content

        "Bearer {{token}}".  {{token}} is the value of an access token obtained

        by following the steps described in

        [Get Access to Quip''s APIs](#section/Authentication/Get-Access-to-Quip''s-APIs).

        The only endpoints that don''t require an Authorization header are these

        Authentication endpoints:

        [Token Endpoint](https://quip.com/dev/automation/documentation/current#operation/accessToken),

        [Authorization Endpoint](https://quip.com/dev/automation/documentation/current#operation/authorization),

        [Revoke a Token](https://quip.com/dev/automation/documentation/current#operation/revokeToken).


        This table lists the URLs for Quip''s Authentication endpoints that you

        can call when you build your integrations. In addition, this table

        describes available scopes for the Automation API. See the

        [Domain Authentication](#section/Domain-Authentication)

        section and the reference documentation linked to in this table for

        information about using the authentication endpoints.

        '
      flows:
        authorizationCode:
          authorizationUrl: https://platform.quip.com/1/oauth/login
          tokenUrl: https://platform.quip.com/1/oauth/access_token
          refreshUrl: https://platform.quip.com/1/oauth/access_token
          scopes:
            USER_READ: Provides access to GET calls that read data.
            USER_WRITE: Provides access to POST, DELETE, and PATCH calls that edit
              data.
            USER_MANAGE: 'Provides access to API calls that perform actions requiring
              full access to a thread or folder. Examples: add or remove thread or
              folder access, lock or unlock a thread.'
      type: oauth2
  parameters:
    folder_include_chats:
      name: include_chats
      in: query
      schema:
        type: boolean
      description: 'If `true`, the `children` list in the response will include chat
        and

        channel thread IDs.

        '
    folder_id_or_secret_path:
      name: folderIdOrSecretPath
      in: path
      schema:
        type: string
        minLength: 10
        maxLength: 32
      required: true
      description: 'Identifier of the folder whose link sharing settings you want
        to get.

        You can pass in either of these identifiers:


        * `folder_id`: Identifier returned in the id field when you call the

        [Get Folder](#operation/getFolder) API method.


        * `secret path`: 12-character identifier that you can find in the URL of

        the folder. For example, the secret path is "N5aaOTih0VYy" in this URL:

        "https://quip.com/N5aaOTih0VYy/TeamFolder".

        '
    thread_id_or_secret_path:
      name: threadIdOrSecretPath
      in: path
      schema:
        type: string
        minLength: 10
        maxLength: 32
      required: true
      description: 'The ID or secret path of the thread you want to modify. You can
        pass in either of these identifiers:

        * `ID` : You can find this in the "id" response field of the [Get Thread](#operation/getThread)
        API method.

        * `secret path` : You can find this in the URL of a thread. For example, in
        this URL: "https://quip.com/3fs7B2leat8/TrackingDocument", the secret path
        is 3fs7B2leat8. You can find this in "secret_path" response field of the [Get
        Thread](#operation/getThread) API method.'
    thread_id_or_secret_path_for_get:
      name: threadIdOrSecretPath
      in: path
      schema:
        type: string
        minLength: 10
        maxLength: 32
      required: true
      description: 'The ID or secret path of the thread to get information about.
        You can pass in either of these identifiers:

        * `ID` : You can find this in the "id" response field of the [Get Thread](#operation/getThread)
        API method.

        * `secret path` : You can find this in the URL of a thread. For example, in
        this URL: "https://quip.com/3fs7B2leat8/TrackingDocument", the secret path
        is 3fs7B2leat8. You can find this in "secret_path" response field of the [Get
        Thread](#operation/getThread) API method.'
    thread_id_or_secret_path_for_folders_patch:
      name: threadIdOrSecretPath
      in: path
      schema:
        type: string
        minLength: 10
        maxLength: 32
      required: true
      description: 'The ID or secret path of the thread to add to folders. You can
        pass in either of these identifiers:

        * `ID` : You can find this in the "id" response field of the [Get Thread](#operation/getThread)
        API method.

        * `secret path` : You can find this in the URL of a thread. For example, in
        this URL: "https://quip.com/3fs7B2leat8/TrackingDocument", the secret path
        is 3fs7B2leat8. You can find this in "secret_path" response field of the [Get
        Thread](#operation/getThread) API method.'
    thread_id_or_secret_path_for_members_patch:
      name: threadIdOrSecretPath
      in: path
      schema:
        type: string
        minLength: 10
        maxLength: 32
      required: true
      description: "The ID or secret path of the thread to add members to. You can\
        \ pass in either of these identifiers:\n\n * `ID` : You can find this in the\
        \ \"id\" response field of the\n [Get Thread](#operation/getThread) API method.\n\
        \n * `secret path` : You can find this in the URL of a thread.\n For example,\
        \ in this URL: \"https://quip.com/3fs7B2leat8/TrackingDocument\",\n the secret\
        \ path is 3fs7B2leat8. You can find this in \"secret_path\"\n response field\
        \ of the [Get Thread](#operation/getThread) API method."
    cursor:
      name: cursor
      in: query
      schema:
        type: string
      required: false
      description: 'A pointer to the next page of data to return. Use a cursor to

        incrementally get additional pages of data. When you call this

        API method for the first time, leave the `cursor` field blank.

        For all calls after that first one, pass in the `next_cursor`

        value returned by your previous call. Continue to call this API

        method with each new `cursor` value until the `next_cursor`

        field returns empty.

        '
    limit:
      name: limit
      in: query
      schema:
        type: number
      required: false
      description: 'The maximum number of items to return in the same call.

        '
  schemas:
    folder_info:
      type: object
      properties:
        folder:
          type: object
          description: Information about the requested folder.
          properties:
            id:
              type: string
              description: The ID of the folder.
              example: RKH9OAELPKV
            title:
              type: string
              description: The title of the folder.
              example: Sales Group
            created_usec:
              type: integer
              format: int64
              description: 'The time that the folder was created, in microseconds

                since UNIX epoch.

                '
            updated_usec:
              type: integer
              format: int64
              description: 'The time that the folder was last changed, in

                microseconds since UNIX epoch.

                '
            color:
              type: string
              description: The color of the folder.
              enum:
              - manila
              - red
              - orange
              - green
              - blue
              - purple
              - dark_yellow
              - light_red
              - light_orange
              - light_green
              - light_blue
              - light_purple
            parent_id:
              type: string
              description: 'The ID of this folders parent, from which it

                inherits permissions, if any.

                '
              example: eSEAOA3jRQ5
            creator_id:
              type: string
              description: The ID of the folder's creator.
              example: KLf9EAPrxbs
            folder_type:
              type: string
              description: 'The type of the folder. Indicated whether this

                folder is private or shared.

                '
              enum:
              - private
              - shared
            inherit_mode:
              type: string
              description: 'If "inherit", this folder''s set of members includes

                its own members as well as its parent folder''s

                members. If "reset", this is a restricted folder and

                only includes its own set of members.

                '
              enum:
              - inherit
              - reset
            link:
              type: string
              description: URL for the folder.
              example: https://acme.quip.com/RKH9OAELPKV
            sharing:
              type: object
              description: 'Information about this folder''s external sharing

                settings.

                '
              properties:
                public:
                  type: string
                  enum:
                  - NONE
                  - VIEW
                  - EDIT
                  description: 'Level of access to this folder allowed for

                    external folder members.

                    '
                  example: VIEW
                company_id:
                  type: string
                  description: 'If set, this is the ID of the external company

                    given access to his folder.

                    '
                  example: IMbAcASGu56
                company_mode:
                  type: string
                  description: 'Level of access to this folder allowed for the

                    external company.

                    '
                  enum:
                  - NONE
                  - VIEW
                  - EDIT
                  example: VIEW
          required:
          - id
          - title
          - created_usec
          - updated_usec
          - creator_id
          - folder_type
          - inherit_mode
        member_ids:
          type: array
          items:
            type: string
          description: List of IDs of this folder's members.
          example:
          - YNK9EAU71mc
          - PEW9EAtTnrV
          - aBd9EAl8R0H
        children:
          type: array
          description: 'List of the folder''s threads and sub-folders. Each object
            represents either a thread or a folder.

            '
          items:
            oneOf:
            - type: object
              properties:
                thread_id:
                  type: string
                  description: 'The ID of a thread that belongs to this folder.

                    '
                  example: TVfAAAGtWxs
              required:
              - thread_id
            - type: object
              properties:
                folder_id:
                  type: string
                  description: The ID of the child folder.
                  example: KRJAOAejuDu
                restricted:
                  type: boolean
                  default: true
                  description: 'This field will be present if the user making the
                    request does not have access to one of the child entities. This
                    field will only ever be `true` if present.

                    '
              required:
              - folder_id
      required:
      - folder
      - member_ids
      - children
      example:
        folder:
          title: Quip
          creator_id: KLf9EAPrxbs
          id: RKH9OAELPKV
          created_usec: 1497474937520657
          updated_usec: 1558247457514983
          folder_type: shared
          inherit_mode: inherit
          sharing:
            company_mode: EDIT
            company_id: LbdAcAwVVIA
        member_ids:
        - YNK9EAU71mc
        - PEW9EAtTnrV
        - aBd9EAl8R0H
        - MVT9EACSny8
        - LJa9EAtQi98
        - ROS9EAGOj1u
        children:
        - thread_id: aXM9AASQOGr
        - thread_id: cYX9AAfS6ma
        - thread_id: WVD9AA1grdh
    folder_get_link_sharing_response:
      type: object
      properties:
        link_sharing_enabled:
          type: boolean
          description: 'States whether link sharing is enabled on your specified folder.

            Allowable values are:


            * **True**: Link sharing is enabled.

            * **False**: Link sharing is disabled.

            '
        external_access_allowed:
          type: boolean
          description: 'States whether people outside of your company can access your

            specified folder. Only returned if `link_sharing_enabled` is `True`.

            Allowable values are:


            * **True**: External access is enabled.

            * **False**: External access is disabled.

            '
      required:
      - link_sharing_enabled
      example:
      - link_sharing_enabled: true
        external_access_allowed: false
    folder_put_link_sharing_request:
      type: object
      properties:
        link_sharing_enabled:
          type: boolean
          description: 'Determines whether to enable link sharing for your specified
            folder.

            Allowable values are:


            * **True**: Enable link sharing.

            * **False**: Disable link sharing.

            '
        external_access_allowed:
          type: boolean
          description: 'Determines whether people outside of your company can access
            your

            specified folder. This field is required only if you set

            `link_sharing_enabled` to `True`. Allowable values are:


            * **True**: Enable external access.

            * **False**: Disable external access.

            '
      required:
      - link_sharing_enabled
      example:
      - link_sharing_enabled: true
        external_access_allowed: false
    message_record:
      type: object
      description: Details of a message.
      properties:
        id:
          type: string
          description: Unique ID of this message
          example: FCKADA33rNg
        author_id:
          type: string
          description: Unique ID of the author of the thread.
          example: UTUAEAiZl6B
        author_name:
          type: string
          description: Name of the user who created the message.
          example: Jane Doe
        created_usec:
          type: integer
          format: int64
          description: 'Time that the message was created, in microseconds since UNIX
            epoch.

            '
          example: 1632348632519081
        updated_usec:
          type: integer
          format: int64
          description: 'Time that the message was last updated, in microseconds since
            UNIX

            epoch.

            '
          example: 1632348632596233
        visible:
          type: boolean
          description: True if this message is currently visible.
        text:
          type: string
          description: Message text.
        files:
          type: array
          items:
            type: object
            properties:
              hash:
                type: string
                description: The hash of the file.
              name:
                type: string
                description: The name of the file.
            required:
            - hash
            - name
          description: 'A list of objects with information about files attached to
            the

            message.

            '
          example:
          - hash: vOTFW_A3Cp1zXNSjqsEIoA
            name: hello.txt
        annotation:
          description: 'For a comment message, information about what the comment
            refers to.

            '
          properties:
            id:
              type: string
              description: ID of the section in the document to which the comment
                is attached. If there are replies to a comment, the original message
                and the replies will have the same value for this field.
            highlighted_section_ids:
              type: array
              items:
                type: string
              description: 'List of unique IDs of document sections highlighted by
                this

                comment.

                '
          required:
          - id
        parts:
          type: array
          description: 'A list of the rich content parts of this message. Each

            rich content part is represented as a two-item list.


            The first list item describes the style of the message.

            Possible values are:

            * `system`

            * `body`

            * `monospace`

            * `status`


            The second list item is the content of the message part,

            in HTML.



            Rich content parts may also include user mentions. Users

            can be mentioned with a link to their user ID appended to

            the end of the Quip URL or with their email: `[["body",

            "<a href=https://quip.com/{user_id}>User name</a>"]]` or

            `[["body", "<a href=mailto:{user_email}>User name</a>"]]`



            For mentioning everyone in a document, a link to @everyone

            is included: `[["body", "<a href=''@everyone''></a>"]]`

            '
          items:
            type: array
            items:
              type: string
            minItems: 2
            maxItems: 2
          example:
          - - system
            - HTML1
          - - status
            - HTML2
        apparent_user:
          type: object
          description: 'The apparent user of the message if it was created by an external

            Quip integration (for example, Github commits in a Quip channel).

            '
          properties:
            user_id:
              type: string
              description: The ID of the apparent user.
        diff_groups:
          description: For an edit document message, the groups of diffs in this edit.
          type: array
          items:
            allOf:
            - $ref: '#/components/schemas/diff_group'
        like_user_ids:
          type: array
          items:
            type: string
          description: 'The list of IDs of users that have reacted to this message.

            '
        mention_user_ids:
          type: array
          items:
            type: string
          description: 'The list of IDs of users that have been @mentioned in this

            message.

            '
      required:
      - id
      - author_id
      - created_usec
      - updated_usec
      - visible
    diff_group:
      description: A group of diffs.
      type: object
      properties:
        diffs:
          type: array
          items:
            allOf:
            - $ref: '#/components/schemas/diff'
      required:
      - diffs
    diff:
      description: Description of a change to a document.
      type: object
      properties:
        diff_class:
          description: "Describes the type of change.\n* `track_changes`: This diff\
            \ will contain a section of the document,\n  annotated to indicate the\
            \ modifications made to that section.\n* `delete_only`: This diff indicates\
            \ only deletions.\n* `insert_only`: This diff indicates only insertions.\n\
            * `insert_completely`: This diff indicates only the insertion of\n  complete\
            \ sections.\n"
          type: string
          enum:
          - track_changes
          - delete_only
          - insert_only
          - insert_completely
        section_id:
          description: Unique ID of the section that was modified.
          type: string
        style:
          description: Style of the content that was changed.
          type: string
      required:
      - diff_class
      oneOf:
      - $ref: '#/components/schemas/single_diff'
      - $ref: '#/components/schemas/list_diff'
      - $ref: '#/components/schemas/spreadsheet_diff'
      - $ref: '#/components/schemas/image_diff'
    single_diff:
      type: object
      properties:
        rtml:
          allOf:
          - $ref: '#/components/schemas/rtml_in_diff'
      required:
      - rtml
    list_diff:
      type: object
      properties:
        list:
          type: array
          items:
            type: object
            properties:
              indentation:
                description: Indentation level of this section.
                type: integer
                format: int32
              section_id:
                description: Section ID of this section.
                type: string
              rtml:
                allOf:
                - $ref: '#/components/schemas/rtml_in_diff'
    spreadsheet_diff:
      type: object
      properties:
        inserted_table_cells_and_headers:
          description: Section IDs of inserted table cells and/or headers.
          type: array
          items:
            type: string
        table_rows:
          description: Information about changed table rows.
          type: array
          items:
            type: object
            properties:
              headers:
                description: Information about changes to headers.
                type: array
                items:
                  type: object
                  properties:
                    rtml:
                      allOf:
                      - $ref: '#/components/schemas/rtml_in_diff'
                    section_id:
                      description: ID of header section
                      type: string
                    width:
                      description: width of header (and column)
                      type: number
                      example: 6.0
              cells:
                description: Information about changes to non-header cells.
                type: array
                items:
                  type: object
                  properties:
                    rtml:
                      allOf:
                      - $ref: '#/components/schemas/rtml_in_diff'
                    section_id:
                      description: ID of cell section
                      type: string
    image_diff:
      type: object
      properties:
        images:
          type: array
          items:
            type: object
            properties:
              height:
                type: integer
                format: int32
                minimum: 1
              width:
                type: integer
                format: int32
                minimum: 1
              is_video_thumbnail:
                type: boolean
              src_url:
                description: Relative URL path of blob resource for image.
                type: string
    rtml_in_diff:
      description: 'Content of the change, in RTML format, with changes wrapped

        in "diff" tags.

        '
      type: string
      example: 'Cats are <diff class="insert">sometimes</diff>

        <diff class="delete">usually</diff> friendly.

        '
    message_parts_input:
      allOf:
      - $ref: '#/components/schemas/message_record/properties/parts'
      - maxItems: 20
    access_level:
      type: string
      description: 'Each user''s access level on the specified thread (Quip document,
        spreadsheet, or chat). This field is required. Possible access levels are:

        * `own`: The user can edit, comment on, and share the thread.

        * `edit`: The user can edit and comment on the thread.

        * `comment`: The user can read and comment on the thread.

        * `view`: The user can only read the thread.'
      enum:
      - own
      - edit
      - comment
      - view
    thread_info_v1:
      description: Full information about a thread.
      type: object
      properties:
        thread:
          allOf:
          - $ref: '#/components/schemas/thread_record_v1'
        markdown:
          type: string
          description: Document content in Markdown.
        invited_user_emails:
          description: Emails of all users invited to this thread.
          type: array
          items:
            type: string
        shared_folder_ids:
          description: IDs of all folders that contain this thread.
          type: array
          items:
            type: string
        user_ids:
          description: 'IDs of all users who have access to this thread because they
            were

            given direct access or were added to the folder that contains

            this thread.

            '
          type: array
          items:
            type: string
        expanded_user_ids:
          description: 'IDs of all users who have access to this thread because they

            were added to the folder that contains this thread.

            '
          type: array
          items:
            type: string
        access_levels:
          description: Map of user IDs to access levels.
          additionalProperties:
            type: object
            properties:
              access_level:
                description: 'Level of access that this user has to this thread.



                  * OWN : Full access, can view, edit, and share.

                  * EDIT : Can edit, but not share.

                  * COMMENT : Can only read and comment

                  * VIEW : Read only access.

                  '
                type: string
                enum:
                - OWN
                - EDIT
                - COMMENT
                - VIEW
            example:
              USER_ID_1:
                access_level: OWN
              FOLDER_ID_2:
                access_level: COMMENT
        html:
          description: 'HTML representation of the document. Only returned if the
            thread is

            a document.

            '
          type: string
      required:
      - thread
      - user_ids
      - shared_folder_ids
      - expanded_user_ids
      - invited_user_emails
      example:
        thread:
          id: AVN9AAeqq5w
          author_id: LJa9EAtQi98
          owning_company_id: IMbAcASGu56
          thread_class: document
          created_usec: 1519926805974011
          updated_usec: 1558224928731511
          title: "\u2757\uFE0F very important cat pics \u2757\uFE0F"
          link: https://corp.quip.com/klUsAqWxr8Ne
          type: document
          is_deleted: false
          is_template: false
          document_id: KSRABARYWW9
        user_ids:
        - UTUAEAiZl6B
        shared_folder_ids:
        - RKa9OAiGmsC
        expanded_user_ids:
        - PZF9EA0i0ef
        - dHe9EABHRsb
        - EHY9EAokwO3
        invited_user_emails: []
        access_levels:
          PZF9EA0i0ef:
            access_level: OWN
          dHe9EABHRsb:
            access_level: VIEW
          EHY9EAokwO3:
            access_level: EDIT
        html: '...'
    thread_record_v1:
      type: object
      description: Information about a thread.
      properties:
        id:
          description: This is the `thread_id`.
          type: string
        author_id:
          description: Unique user ID of the author of this thread.
          type: string
        created_usec:
          description: The [Unix timestamp](https://www.epochconverter.com/) in microseconds
            for when the thread was created.
          type: integer
          format: int64
        updated_usec:
          description: 'The [Unix timestamp](https://www.epochconverter.com/)

            in microseconds for when the thread was last changed. This will

            account for changes to content as well as almost all changes related

            to comments and sharing. Notably, this field currently does NOT

            update for comment reactions and thread removal from folder.

            '
          type: integer
          format: int64
        title:
          description: Title of this thread.
          type: string
        thread_class:
          description: 'Type of thread. Examples: a `channel` is a Slack channel

            conversation linked to Quip, a `tasks_search` thread is made up

            of the assigned tasks in a thread.

            '
          type: string
          enum:
          - document
          - two_person_chat
          - channel
          - group_chat
          - tasks_search
          - file_upload
          example: document
        is_deleted:
          description: 'Returns "true" if this thread has been deleted.

            Returns "false" if this thread hasn''t been deleted.

            '
          type: boolean
        is_template:
          description: 'Returns "true" if this thread is a template.

            Returns "false" if this thread isn''t a template.

            '
          type: boolean
        document_id:
          description: 'The unique ID of the thread. The document_id is different

            from the id and the secret path.

            '
          type: string
        link:
          description: URL that can be used to open this thread.
          type: string
        type:
          type: string
          description: Category that this thread belongs to.
          enum:
          - document
          - spreadsheet
          - slides
          - chat
        owning_company_id:
          type: string
          description: The ID of the company that this thread belongs to.
        snippet_user_id:
          type: string
          description: 'The ID of a user that is displayed for this thread in the
            updates

            view of the Quip app.

            '
        snippet_message:
          type: string
          description: 'Message snippet that is displayed for this thread in the updates

            view of the Quip app.

            '
        sharing:
          type: object
          description: 'Information about sharing of the thread with users outside
            of your

            company.

            '
          properties:
            public:
              type: string
              enum:
              - NONE
              - VIEW
              - EDIT
              description: 'Level of access to this thread allowed for external thread

                members.

                '
              example: VIEW
            company_id:
              type: string
              description: 'ID of the company that owns the thread.

                '
              example: IMbAcASGu56
            company_mode:
              type: string
              description: 'Level of access to this thread allowed for users of the

                company that owns the thread.

                '
              enum:
              - NONE
              - VIEW
              - EDIT
              example: VIEW
      required:
      - id
      - created_usec
      - updated_usec
      - thread_class
      - owning_company_id
    thread_get_v2:
      type: object
      properties:
        thread:
          allOf:
          - $ref: '#/components/schemas/thread_info_v2_without_example'
      example:
        thread:
          author_id: LJa9EAtQi98
          created_usec: 1519926805974011
          id: AVN9AAeqq5w
          is_template: false
          link: https://corp.quip.com/klUsAqWxr8Ne
          owning_company_id: IMbAcASGu56
          secret_path: klUsAqWxr8Ne
          title: "\u2757\uFE0F very important cat pics \u2757\uFE0F"
          type: DOCUMENT
          updated_usec: 1558224928731511
    thread_multi_get_v2:
      type: object
      additionalProperties:
        x-additionalPropertiesName: thread_id
        allOf:
        - $ref: '#/components/schemas/thread_info_v2_without_example'
      example:
        klUsAqWxr8Ne:
          author_id: LJa9EAtQi98
          created_usec: 1519926805974011
          id: AVN9AAeqq5w
          is_template: false
          link: https://corp.quip.com/klUsAqWxr8Ne
          owning_company_id: IMbAcASGu56
          secret_path: klUsAqWxr8Ne
          title: "\u2757\uFE0F very important cat pics \u2757\uFE0F"
          type: DOCUMENT
          updated_usec: 1558224928731511
        abcAAA78901:
          error_description: 'Not found: ''abcAAA78901'''
    thread_info_v2_without_example:
      type: object
      description: 'Information about a thread. The fields returned are:

        '
      properties:
        author_id:
          description: The ID of the user who created the thread.
          type: string
        created_usec:
          description: 'The [Unix timestamp](https://www.epochconverter.com/)

            in microseconds for when the thread was created.

            '
          type: integer
          format: int64
        id:
          description: This is the thread_id.
          type: string
        is_template:
          description: 'Returns "true" if this thread is a template.

            Returns "false" if this thread isn''t a template.

            '
          type: boolean
        link:
          description: Link to the thread.
          type: string
          format: url
        owning_company_id:
          description: 'ID of the company that owns the thread.

            '
          type: string
        secret_path:
          description: 'This is the thread''s identifier that you can find in its
            URL.

            '
          type: string
        sharing:
          type: object
          description: 'Information about the thread''s link sharing settings:

            '
          properties:
            company_id:
              description: 'ID of the company that owns the thread.

                '
              type: string
              example: IMbAcASGu56
            company_mode:
              description: 'Level of access to this thread allowed using its shareable

                link. Possible access levels are:


                *NONE:* Link sharing isn''t enabled on this thread.


                *VIEW:* The shareable link allows users to read the thread.


                *EDIT:* The shareable link allows users to edit and comment

                on the thread.

                '
              enum:
              - NONE
              - VIEW
              - EDIT
              type: string
              example: VIEW
        title:
          description: 'The title of the thread.

            '
          type: string
        type:
          type: string
          description: 'Category that the thread belongs to: document, spreadsheet,
            or chat.

            '
          enum:
          - DOCUMENT
          - SPREADSHEET
          - SLIDES
          - CHAT
        updated_usec:
          description: 'The [Unix timestamp](https://www.epochconverter.com/)

            in microseconds for when the thread was last changed. This will

            account for changes to content as well as almost all changes related

            to comments and sharing. Notably, this field currently does NOT

            update for comment reactions and thread removal from folder.

            '
          type: integer
          format: int64
      required:
      - author_id
      - created_usec
      - id
      - is_template
      - link
      - owning_company_id
      - secret_path
      - title
      - type
      - updated_usec
    new_document_request:
      type: object
      properties:
        format:
          type: string
          enum:
          - html
          - markdown
          default: html
          description: Format of the supplied document content.
        content:
          type: string
          description: 'The HTML or

            [Markdown](https://daringfireball.net/projects/markdown/)

            content of the new document. The content length must not exceed 1MB.


            NOTE: When creating a spreadsheet, the content must be surrounded by

            an HTML `<table>` tag.


            NOTE: In the current implementation, the parser treats `<th>` tags

            as `<td>` tags. When more than one `<tr>` tag is supplied, then the

            first row is automatically interpreted as the column header. If you

            want to create a table with more than one row and have default

            headers, then provide the first row with empty `<td>` tags.'
        title:
          type: string
          description: The title of the new document. If not specified, we infer the
            title from the first content of the document, for example, the first heading.
            The title must not exceed 10 KB.
        member_ids:
          type: string
          description: 'A comma-separated list of folder IDs or user IDs. The document
            will be placed in the specified folders, and any individual users listed
            will be granted individual access to the document. If this argument is
            not given, the document is created in the authenticated user''s Private
            folder.

            '
        type:
          type: string
          enum:
          - document
          - spreadsheet
          default: document
          description: The type of document to create.
      required:
      - content
    copy_document_v1_request:
      type: object
      properties:
        thread_id:
          type: string
          description: 'The ID or secret path of the document to be copied:

            - <b>ID</b>: You can find this in the `id` response field of the

            <a href=https://quip.com/dev/automation/documentation/current#get-thread>

            Get Thread </a> API method.

            - <b>secret path</b>: You can find this in the URL of a thread.

            For example, in this URL:

            "https://quip.com/3fs7B2leat8/TrackingDocument", the secret path

            is <b>3fs7B2leat8</b>.

            '
        values:
          type: string
          description: "If you want to make a copy of a template and fill it in with\
            \ your specified content, pass a JSON dictionary into this field. In the\
            \ JSON dictionary, the keys must be strings and the values must be either\
            \ strings or dictionaries. Keys can contain only the characters A-Z, a-z,\
            \ 0-9, .(period) and _(underscore). For example:\n1. You have a document\
            \ you want to copy that's a template\n   containing these fields:\n\n\
            \   `Name = [[Customer.Name]]`\n\n   `Age = [[Customer.Age]]`\n\n   `\
            \ [[Greeting]], [[Customer.Name]]!`\n\n2. You pass this JSON dictionary\
            \ into the `values` field:\n\n   `{\"Customer\": {\"Age\": 34, \"Name\"\
            : \"Arnie\"}, \"Greeting\": \"Hello\"}`\n\n3. The copy of the document\
            \ displays this content:\n\n   `Name = Arnie`\n\n   `Age = 34`\n\n   `Hello,\
            \ Arnie!`\n"
          example:
            name:
              first: Jane
              last: Smith
            department: Sales
        member_ids:
          type: string
          description: 'Comma-separated list of user IDs of people who can access
            the new

            thread. If you don''t pass in `member_ids`, only the user who

            called this API method has access to the new thread.

            There''s a maximum limit of 100 `member_ids` per request. The default

            access level is Full Access, which means that added users can

            edit, comment on, and share the thread.

            '
        folder_ids:
          type: string
          description: "Comma-separated list of identifiers of the folders you want\
            \ to add\nthe new thread to. If you don't pass in `folder_ids`, the new\n\
            thread is added to the private folder of the user who called this\nAPI\
            \ method. There's a maximum limit of 100 `folder_ids` per request.\nYou\
            \ can pass in either of these identifiers:\n- `folder_id`: Identifier\
            \ returned in the `id` field when you call\nthe <a href=https://quip.com/dev/automation/documentation/current#get-folder>\n\
            \ Get Folder </a> API method.\n- <b>secret path:</b> 12-character identifier\
            \ that you can find in\nthe URL of the folder. For example,\nin this URL:\
            \ \"https://quip.com/N5aaOTih0VYy/TeamFolder\", the secret\npath is <b>N5aaOTih0VYy</b>.\n\
            \n<b>Note:</b> For better performance, it\u2019s recommended that you\n\
            add no more than 1,000 items to a folder. There\u2019s a maximum limit\n\
            of 4,000 items per folder. Items include documents, spreadsheets,\nand\
            \ subfolders. When your API call exceeds the suggested limit of\n1,000\
            \ items, a warning message is returned in the API response.\nWhen your\
            \ API call exceeds the maximum limit of 4,000 items,\nthe request isn\u2019\
            t executed and the 400 error code is returned.\nFor more information,\
            \ see\n<a href=\"https://help.salesforce.com/s/articleView?id=sf.quip_folder_limits.htm\"\
            \ntarget=\"_blank\"> Folder Limits</a>.\n"
        title:
          type: string
          description: 'The name of the new thread. The title is used as the first
            line of a document.

            We recommend that you pass in a `title` to clearly identify the new thread.
            If you don''t pass in a `title`, the names of the original and new threads
            are the same.

            '
        copy_annotations:
          type: boolean
          default: false
          description: "Determines whether to copy comments in the original thread\
            \ to the\nnew thread. Possible values are:\n- <b>true</b>: Comments in\
            \ the original thread are copied to the\n  new thread.\n- <b>false</b>:\
            \ Comments in the original thread aren't copied to\n  the new thread.\n"
      required:
      - thread_id
    copy_document_v2_request:
      type: object
      properties:
        title:
          type: string
          description: The name of the new thread. The title is used as the first
            line of a document. We recommend that you pass in a title to clearly identify
            the new thread. If you don't pass in a title, the names of the original
            and new threads are the same.
        folder_id:
          type: string
          description: "Identifier of the folder you want to add the new thread to.\
            \ If you don't pass in a folder_id, the new thread is added to the private\
            \ folder of the user who called this API method. You can pass in either\
            \ of these identifiers:\n* `folder_id`: Identifier returned in the `id`\
            \ field when you call\n  the [Get Folder](#operation/getFolder) API method.\n\
            * `secret path`: 12-character identifier that you can find in the\n  URL\
            \ of the folder. For example, in this URL:\n  \"https://quip.com/N5aaOTih0VYy/TeamFolder\"\
            , the secret path is\n  N5aaOTih0VYy.\n\n**Note**: Copy a Document or\
            \ Template V2 is faster and more lightweight, so you can pass in only\
            \ one folder ID. Copy a Document or Template V1 allows you to pass in\
            \ multiple folder IDs."
        mail_merge_values:
          type: object
          description: "If you want to make a copy of a template and fill it in with\
            \ your specified content, pass a JSON dictionary into this field. In the\
            \ JSON dictionary, the keys must be strings and the values must be either\
            \ strings or dictionaries. Keys can contain only the characters A-Z, a-z,\
            \ 0-9, .(period) and _(underscore).\nFor example:\n* You have a document\
            \ you want to copy that's a template\n  containing these fields:\n\n \
            \ `Name = [[Customer.Name]]`\n\n  `Age = [[Customer.Age]]`\n\n  ` [[Greeting]],\
            \ [[Customer.Name]]!`\n* You pass this JSON dictionary into the `mail_merge_values`\
            \ field:\n\n  `{\"Customer\": {\"Age\": 34, \"Name\": \"Arnie\"}, \"Greeting\"\
            : \"Hello\"}`\n* The copy of the document displays this content:\n\n \
            \ `Name = Arnie`\n\n  `Age = 34`\n\n  `Hello, Arnie!`"
          maxItems: 1000
        copy_annotations:
          type: boolean
          default: false
          description: 'Determines whether to copy comments in the original thread
            to the new thread. Possible values are:

            * `true`: Comments in the original thread are copied to the new thread.

            * `false`: Comments in the original thread aren''t copied to the new thread.'
      example:
        title: "\u2757\uFE0F very important cat pics \u2757\uFE0F"
        folder_id: N5aaOTih0VYy
        mail_merge_values:
          Customer:
            Age: 34
            Name: Arnie
          Greeting: Hello
        copy_annotations: false
    edit_document_request:
      type: object
      properties:
        thread_id:
          type: string
          description: 'The ID or secret path of the thread whose document you want
            to edit:

            - <b>ID</b>: You can find this in the `id` response field of the

            <a href=https://quip.com/dev/automation/documentation/current#get-thread>

            Get Thread </a> API method.

            - <b>secret path</b>: You can find this in the URL of a thread.

            For example, in this URL:

            "https://quip.com/3fs7B2leat8/TrackingDocument", the secret path

            is <b>3fs7B2leat8</b>.

            '
        format:
          type: string
          description: 'Format of the `content` field. Required unless `location`

            is 5 (DELETE_SECTION).

            '
          enum:
          - html
          - markdown
          default: html
        content:
          type: string
          description: "The HTML or [Markdown](https://daringfireball.net/projects/markdown/)\
            \ for the content that you want to add. There's a maximum limit of 1 MB\
            \ of content per request.\nYou can add a live app by using a `<div>` tag\
            \ containing these values in the content field:\n* `data-live-app-id`:\
            \ ID of the type of live app you want to add.\n  For your company, this\
            \ ID is always the same for the same type\n  of live app. For a live app\
            \ currently in a document, you can\n  find this ID in the `html` field\
            \ returned by the\n  [Get Thread](https://quip.com/dev/automation/documentation/current#get-thread)\n\
            \   API method. For example, for a calendar, you can call the\n  [Get\
            \ Thread](https://quip.com/dev/automation/documentation/current#get-thread)\n\
            \   API and the `html` field returns something similar to:\n   **data-live-app-id='AbNBjAC13no'**.\
            \ Pass **'AbNBjAC13no'**\n  into the content field every time you want\
            \ to add a calendar to\n  a document.\n* `data-live-app-payload`: A JSON\
            \ string containing the data\n  that you want to include in the live app.\n\
            \n**Note**: We support most of the Markdown tags. The exceptions are described\
            \ in the [differences](https://python-markdown.github.io/#differences)\
            \ in the Python-Markdown implementation."
        section_id:
          type: string
          description: "The ID of the part of the thread where you want to add content.\
            \ Each of these types of content has its `own section_id`: paragraph,\
            \ list item, graphic, spreadsheet row, spreadsheet or live app cell, and\
            \ live app. This field is required if the location is `AFTER_SECTION`,\
            \ `BEFORE_SECTION`, `REPLACE_SECTION`, or `DELETE_SECTION`. Provide either\
            \ a `section_id` or a `document_range`.\n* To find a section_id for all\
            \ content except live app and\n  spreadsheet data:\n    * Select content\
            \ in a thread and use this keyboard shortcut\n    to copy a link to the\
            \ content:\n      * **Windows**: Ctrl + Shift + A\n      * **Mac**: Command\
            \ + Shift + A\n\n    Paste the link into a text editor. The `section_id`\n\
            \    is after the \"#\". For example, in this link:\n    \"https://quip.com/vXYlZwL8Ul35/CustomerFeedback#temp:C:UHA3342fed2be3f401fb513dc0cf\"\
            ,\n    the `section_id` is **temp:C:UHA3342fed2be3f401fb513dc0cf**.\n\n\
            * To find a `section_id` for all content including live app and\n  spreadsheet\
            \ data (for embedded and standalone spreadsheets):\n  * Call the [Get\
            \ Thread](https://quip.com/dev/automation/documentation/current#get-thread)\n\
            \    API method and locate the ID for each HTML element in the\n    `html`\
            \ response field. For example:\n     * In this HTML data:\n     `<div\
            \ id='temp:C:HcD011418d4e25fe057d98300b99'>`, the\n     `section_id` for\
            \ the corresponding **live app**\n     is **temp:C:HcD011418d4e25fe057d98300b99**.\n\
            \     * In this HTML data:\n     `<span id='temp:C:HcDe1a29801dd43ce5b7d68c43f3'>`,\n\
            \     the `section_id` for the corresponding **live app cell**\n     is\
            \ **temp:C:HcDe1a29801dd43ce5b7d68c43f3**.\n     * In this HTML data:\n\
            \     `<span id='temp:s:HcDABA078jM_temp:C:HcD5aa735cfd0dd58e3eee0e5ef0'>`,\n\
            \     the `section_id` for the corresponding **spreadsheet row**\n   \
            \  is temp:s:HcDABA078jM.\n     * In this HTML data: `<span id='temp:s:HcDABA078jM_temp:C:HcD5aa735cfd0dd58e3eee0e5ef0'>`,\n\
            \     the `section_id` for the corresponding **spreadsheet cell**\n  \
            \   is **temp:s:HcDABA078jM_temp:C:HcD5aa735cfd0dd58e3eee0e5ef0**."
        document_range:
          type: string
          description: "The text of the heading of the document range you want to\
            \ modify. The document range includes the heading and all subheadings\
            \ below it up to the next heading of the same size or larger. Required\
            \ if the `location` is `AFTER_DOCUMENT_RANGE`, `BEFORE_DOCUMENT_RANGE`,\
            \ `REPLACE_DOCUMENT_RANGE`, or `DELETE_DOCUMENT_RANGE`. This parameter\
            \ supports only documents and not spreadsheets. Provide either a `section_id`\
            \ or a `document_range`.\nFor example:\n* If you have content in this\
            \ heading structure:\n  * Topic 1\n  * Topic 2\n    * Subtopic 2.1\n \
            \     * Subtopic 2.1.1\n  * Topic 3\n* Then you delete `document_range`\
            \ Topic 2:\n  * All of the content from Topic 2 to Subtopic 2.1.1\n  and\
            \ the text under those headings are deleted.\n  * Only Topic 1 and Topic\
            \ 3 are left in the document."
        location:
          description: "Where we should insert the new content.\n\n\n  * `0: APPEND`\
            \ - Add to the end of the document. This isn't\n    supported for a standalone\
            \ spreadsheet. To add a row at the\n    end of a standalone spreadsheet,\
            \ pass in the `section_id` of\n    the last row in the spreadsheet and\
            \ use `location` **2**.\n  * `1: PREPEND` - Add to the beginning of the\
            \ document. This\n    isn't supported for a standalone spreadsheet. To\
            \ add a\n    row at the beginning of a standalone spreadsheet,\n    pass\
            \ in the `section_id` of the first row in the\n    spreadsheet and use\
            \ `location` **3**.\n  * `2: AFTER_SECTION` - Insert after the section\
            \ specified\n    by section_id.\n  * `3: BEFORE_SECTION` - Insert before\
            \ the section\n    specified by section_id.\n  * `4: REPLACE_SECTION`\
            \ - Delete the section specified by\n    `section_id` and insert the new\
            \ content at that location.\n    This isn't supported for live apps. You\
            \ can delete a\n    live app and add another one with your chosen content.\n\
            \  * `5: DELETE_SECTION` - Delete the section specified by\n    section_id\
            \ (no content required).\n  * `6: AFTER_DOCUMENT_RANGE` - Insert after\
            \ the document\n    range specified by `document_range`.\n  * `7: BEFORE_DOCUMENT_RANGE`\
            \ - Insert before the document\n    range specified by `document_range`.\n\
            \  * `8: REPLACE_DOCUMENT_RANGE` - Delete the document range\n    specified\
            \ by `document_range` and insert the new content\n    at that location.\n\
            \  * `9: DELETE_DOCUMENT_RANGE` - Delete the document range\n    specified\
            \ by `document_range` (no content required)."
          type: integer
          enum:
          - 1
          - 2
          - 3
          - 4
          - 5
          - 6
          - 7
          - 8
          - 9
          default: 0
      required:
      - thread_id
    edit_document_response:
      allOf:
      - $ref: '#/components/schemas/thread_info_v1'
      - properties:
          section_ids:
            type: array
            items:
              type: string
            description: List of IDs for each piece of content you added or edited
              using this API call. You can use the `section_id` to state where you
              want to add new content when you call this API method again. If you
              delete content, no `section_id` is returned. See the `section_id` part
              of the request body documentation for more details.
    thread_get_html_v2_response:
      type: object
      properties:
        html:
          type: string
          description: 'The document content rendered as HTML. Elements that correspond
            to document sections will have their section ids rendered as the "id"
            tag.

            '
          example: <h1 id='SUUACAWNxIJ'>Welcome to Quip</h1><p id='SUUACAxnYSJ' class='line'>Quip
            lets you do much more than just create and edit documents online. Try
            it out and see for yourself!</p>
        response_metadata:
          allOf:
          - $ref: '#/components/schemas/response_metadata'
      required:
      - html
    thread_add_members_v1_request:
      allOf:
      - type: object
        properties:
          thread_id:
            type: string
            description: 'The ID or secret path of the thread to get information about.
              You can pass in either of these identifiers:

              * **ID**: You can find this in the "id" response field of the [Get Thread](#operation/getThread)
              API method.

              * **Secret path**: You can find this in the URL of a thread. For example,
              in this URL: "https://quip.com/3fs7B2leat8/TrackingDocument", the secret
              path is 3fs7B2leat8. You can find this in "secret_path" response field
              of the [Get Thread](#operation/getThread) API method.

              '
        required:
        - thread_id
      - oneOf:
        - type: object
          properties:
            member_ids:
              type: string
              description: "A comma-separated list of folder IDs and user IDs. We\
                \ add each user individually to the thread. We add the thread to each\
                \ of the specified folder IDs.\nIf you pass in a folder ID, use either\
                \ of these folder identifiers:\n* **Folder id**: Identifier returned\
                \ in the `id` field when you call the [Get Folder](#operation/getFolder)\
                \ API method.\n* **Secret path**: 12-character identifier that you\
                \ can find in the URL of the folder. For example, in the URL \"https://quip.com/N5aaOTih0VYy/TeamFolder\"\
                , the secret path is N5aaOTih0VYy.\n\nThe `member_ids` field is required\
                \ if you didn't pass in a `member_ids_by_access_level` value. If you\
                \ pass in a `member_ids value` instead of a `member_ids_by_access_level`,\
                \ the access level defaults to Full Access.\n\n**Note:** For better\
                \ performance, it\u2019s recommended that you add no more than 1,000\
                \ items to a folder. There\u2019s a maximum limit of 4,000 items per\
                \ folder. Items include documents, spreadsheets, and subfolders. When\
                \ your API call exceeds the suggested limit of 1,000 items, a warning\
                \ message is returned in the API response. When your API call exceeds\
                \ the maximum limit of 4,000 items, the request isn\u2019t executed\
                \ and the 400 error code is returned. For more information, see [Folder\
                \ Limits]( https://help.salesforce.com/s/articleView?id=sf.quip_folder_limits.htm).\n"
          required:
          - member_ids
        - type: object
          properties:
            member_ids_by_access_level:
              type: string
              description: "Each user's access level on the specified thread\nas a\
                \ JSON\narray. This field is required if you didn't pass in a\n`member_ids`\
                \ value. Possible access levels are:\n\n* `0`: Full Access - The user\
                \ can edit, comment on,\n  and share the thread.\n* `1`: Edit - The\
                \ user can edit and comment on the\n  thread.\n* `2`: Comment - The\
                \ user can read and comment on\n  the thread.\n* `3`: View - The user\
                \ can only read the thread.\n\nExample:\n`[{\"access_level\": 0, \"\
                member_ids\": [\"user_id_1\"]},\n{\"access_level\": 3, \"member_ids\"\
                : [\"user_id_2\"]}]\n`\n"
          required:
          - member_ids_by_access_level
    thread_remove_members_v1_request:
      type: object
      properties:
        thread_id:
          type: string
          description: 'The ID or secret path of the thread from which you want to
            remove folders and users.

            '
        member_ids:
          type: string
          description: A comma-separated list of folder IDs and user IDs. We remove
            each user ID individually from the thread. We remove the thread from each
            of the specified folder IDs.
      required:
      - thread_id
      - member_ids
    thread_get_members_v2_response:
      type: object
      properties:
        members:
          type: array
          description: Array of user IDs of the thread members along with their access
            levels.
          maxItems: 100
          items:
            type: object
            properties:
              access_level:
                allOf:
                - $ref: '#/components/schemas/access_level'
              user_id:
                type: string
                description: The user ID of each thread member.
              id:
                type: string
                description: The ID of each thread member.
            required:
            - access_level
            - user_id
            - id
          example:
          - access_level: EDIT
            user_id: LJa9EAtQi98
            id: dAWAFAAarIo
          - access_level: OWN
            user_id: BfNAEA8gUaD
            id: dAWAFAiFVnw
        response_metadata:
          allOf:
          - $ref: '#/components/schemas/response_metadata'
      required:
      - members
    thread_get_invited_members_v2_response:
      type: object
      properties:
        invited_members:
          type: array
          items:
            type: object
            description: Information about an invited user.
            properties:
              email:
                type: string
                description: 'The email address of each invited member.

                  Note: This API method doesn''t return the email addresses of users
                  who are already direct members of a thread.

                  '
              access_level:
                $ref: '#/components/schemas/access_level'
              id:
                type: string
                description: The ID of each invited thread member.
          example:
          - email: abc@example.com
            access_level: OWN
            id: fONAVAw8BJX
          - email: def@example.com
            access_level: VIEW
            id: SWJAVAhaLJ6
          maxItems: 100
        response_metadata:
          allOf:
          - $ref: '#/components/schemas/response_metadata'
    thread_add_members_v2_request:
      type: object
      properties:
        updated_members:
          type: array
          description: 'JSON array of user IDs or email addresses of people who can
            access the thread along with their access levels. You can add a maximum
            of 100 users per request. The fields in this array are:'
          example:
          - access_level: edit
            email: joe@doe.com
          - access_level: own
            user_id: LJa9EAtQi98
          - access_level: comment
            user_id: DEF4545$
          maxItems: 100
          items:
            allOf:
            - type: object
              properties:
                access_level:
                  $ref: '#/components/schemas/access_level'
              required:
              - access_level
            - oneOf:
              - type: object
                properties:
                  user_id:
                    type: string
                    description: 'The user ID of each person who can access the thread.
                      This field is required if you didn''t pass in an email.

                      '
                required:
                - user_id
              - type: object
                properties:
                  email:
                    type: string
                    description: 'The email address of each person who can access
                      the thread. This field is required if you didn''t pass in a
                      user_id.

                      '
                required:
                - email
      required:
      - updated_members
    thread_add_members_v2_response:
      description: Add member V2 endpoint response
      type: object
      properties:
        updated_members:
          type: array
          description: 'Array of user IDs or email addresses of people who can access
            the thread along with their access levels. The fields returned are:'
          maxItems: 100
          items:
            allOf:
            - type: object
              properties:
                access_level:
                  $ref: '#/components/schemas/access_level'
                accepted:
                  type: boolean
                  description: 'States whether your request to add members is accepted.  Possible
                    values are:

                    * `true`: The request was successful.

                    * `false`: The request was unsuccessful because a required field
                    is missing or you passed in an invalid user_id or email.'
                error_message:
                  type: string
                  description: A message is returned if the accepted field returns
                    false. It provides information about what went wrong.
              required:
              - access_level
              - accepted
            - oneOf:
              - type: object
                properties:
                  user_id:
                    type: string
                    description: 'The user ID of each person who can access the thread.
                      Either a user_id or email address is returned based on what
                      you passed into the API call.

                      '
                required:
                - user_id
              - type: object
                properties:
                  email:
                    type: string
                    description: 'The email address of each person who can access
                      the thread. This field is required if you didn''t pass in a
                      user_id. Either a user_id or email address is returned based
                      on what you passed into the API call.

                      '
                required:
                - email
      required:
      - updated_members
      example:
      - access_level: edit
        email: joe@doe.com
        accepted: true
      - access_level: own
        user_id: LJa9EAtQi98
        accepted: true
      - access_level: comment
        user_id: DEF4545$
        accepted: false
        error_message: Invalid user_id.
    thread_get_folders_v2_response:
      type: object
      properties:
        folders:
          type: array
          items:
            type: object
            example:
            - folder_id: XaABCAlgycE
              type: SHARED
            - folder_id: EGFAOAZ64Jg
              type: PRIVATE
            properties:
              folder_id:
                type: string
                description: 'The ID of each folder that the thread is in.

                  '
              type:
                type: string
                description: 'The type of the folder. Possible values are

                  * `PRIVATE`: The folder is private to a single user.

                  * `SHARED`: The folder is shared among users.

                  '
                enum:
                - PRIVATE
                - SHARED
          maxItems: 100
        response_metadata:
          allOf:
          - $ref: '#/components/schemas/response_metadata'
    thread_add_to_folders_v2_request:
      type: object
      properties:
        folders:
          type: array
          description: 'JSON array of IDs for the folders to add the thread to along
            with the thread''s access level in each folder. You can add a thread to
            a maximum of 100 folders per request and 2,500 folders across multiple
            requests. The fields in this array are:'
          example:
          - access_level: edit
            folder_id: XaABCAlgycE
          - access_level: own
            folder_id: LJa9EAtQi98
          - access_level: comment
            folder_id: XaXYZAlgycE
          maxItems: 100
          items:
            allOf:
            - type: object
              properties:
                access_level:
                  $ref: '#/components/schemas/access_level'
                folder_id:
                  type: string
                  description: The ID of each folder to add the thread to.
              required:
              - access_level
              - folder_id
      required:
      - folders
    thread_add_to_folders_v2_response:
      description: Add thread to folders V2 endpoint response
      type: object
      properties:
        folders:
          type: array
          description: 'Array of IDs for the folders that the thread was added to
            along with the thread''s access level in each folder. The fields returned
            are:'
          example:
          - access_level: edit
            folder_id: XaABCAlgycE
            accepted: true
          - access_level: own
            user_id: LJa9EAtQi98
            accepted: true
          - access_level: comment
            user_id: XaXYZAlgycE
            accepted: false
            error_message: Invalid folder_id.
          maxItems: 100
          items:
            allOf:
            - type: object
              properties:
                access_level:
                  $ref: '#/components/schemas/access_level'
                folder_id:
                  type: string
                  description: The ID of each folder that the thread was added to.
                accepted:
                  type: boolean
                  description: 'States whether your request to add a thread to folders
                    is accepted. Possible values are:

                    * `true`: Your request was scheduled successfully.

                    `Note`: Depending on factors such as the volume of content in
                    the same folders as the thread, it can take up to several minutes
                    to complete a request.

                    * `false`: The request was unsuccessful because a required field
                    is missing or you passed in an invalid `folder_id`.'
                error_message:
                  type: string
                  description: A message is returned if the accepted field returns
                    `false`. It provides information about what went wrong.
              required:
              - access_level
              - folder_id
              - accepted
      required:
      - folders
    thread_edit_share_link_request:
      type: object
      properties:
        thread_id:
          type: string
          description: 'The ID or secret path of the thread whose share link settings
            you

            want to edit.

            '
        allow_external_access:
          type: boolean
          description: Determines whether users outside your company can access the
            Quip thread. If `true`, users outside your company can access the Quip
            thread. If `false`, users outside your company can't access the Quip thread.
        mode:
          type: string
          enum:
          - edit
          - view
          - none
          description: Indicates the access that users will have to the thread.
        enable_request_access:
          type: boolean
          description: Allow users to request access to the document. When a user
            tries to access a document that they don't have access to,  they are presented
            with a dialog informing them they do not have access to this document.
            If `enable_request_access` is `true`, this dialog will contain a "Request
            Access" button.
        show_conversation:
          type: boolean
          description: Determines whether users can see the conversation pane in a
            Quip thread. If `true`, users can see the conversation pane. If `false`,
            users can't see the conversation pane.
        show_edit_history:
          type: boolean
          description: Determines whether users can see a Quip thread's edit history
            in the conversation pane. If `true`, users can see the edit history. If
            `false`, users can't see the edit history.
        allow_messages:
          type: boolean
          description: 'Determines whether users can add comments to an existing

            conversation in a Quip thread. If `true`, users can add comments to

            an existing conversation. If `false`, users can''t add comments to an

            existing conversation.

            '
        allow_comments:
          type: boolean
          description: 'Determines whether users can add new comments to a Quip thread.
            If

            `true`, users can add new comments. If `false`, users can''t add new

            comments.

            '
      required:
      - thread_id
      minProperties: 3
    thread_delete_request:
      type: object
      properties:
        thread_id:
          type: string
          description: 'The ID or secret path of the thread to delete.

            '
        wipeout:
          type: boolean
          default: false
          description: Whether to permanently delete the thread.
      required:
      - thread_id
    get_bulk_export_response:
      type: object
      properties:
        completed:
          type: boolean
          description: 'States whether the export process was completed. Possible

            values are:

            * `true`: Export processing was completed (successfully or

            otherwise) for all requests in this batch.

            * `false`: Export processing is in progress for at least one request

            in this batch.

            '
        results:
          description: 'Array of exported their PDF URLs and statuses

            '
          type: array
          items:
            type: object
            properties:
              thread_id:
                type: string
                description: 'The ID of the thread for the document or spreadsheet
                  you want

                  to export.

                  '
              status:
                type: string
                enum:
                - PROCESSING
                - EXPORTED
                - FAILURE
                - OMITTED_DUE_TO_TIMESTAMP
                - NO_ACCESS
                - INCOMPATIBLE_FORMAT
                - FILE_TOO_LARGE
              file_url:
                type: string
                description: "URL that can be used to retrieve the exported file.\
                  \ Access\nto this URL requires an `Authorization` header. When\n\
                  `file_size` is larger than 209,715,200 bytes (200MB), please\nfetch\
                  \ the data by sending multiple requests and sending a\n `Range`\
                  \ header along with each request, as documented\n[here](https://www.rfc-editor.org/rfc/rfc9110.html#name-range)\n\
                  . (Note that multiple ranges in a single request are not\nsupported.)\
                  \ Recommended size for each request is 100MB or\nless.\nThis field\
                  \ is present when status is `EXPORTED`.\n"
              file_size:
                type: integer
                description: 'The number of bytes in this exported file.

                  This field is present when status is `EXPORTED`.

                  '
            required:
            - thread_id
            - status
          example:
          - thread_id: UcZ9AAhvqrc
            status: EXPORTED
            file_url: https://corp.quip.com/-/blob/UcZ9AAhvqrc/3aXoBEvHxahzUtBse0799g?name=UcZ9AAhvqrc.pdf&expiring=true
          - thread_id: AVN9AAeqq5w
            status: PROCESSING
    get_bulk_export_pdf_response:
      type: object
      properties:
        completed:
          type: boolean
          description: 'States whether the PDF export process was completed. Possible

            values are:

            * `true`: The PDF export process was completed successfully or

            unsuccessfully.

            * `false`: The PDF export process is in progress.

            '
        overall_status:
          type: object
          description: The overall status of your request.
          properties:
            processing:
              type: integer
              description: The number of PDF exports are in progress.
              minimum: 0
              example: 0
            success:
              type: integer
              description: The number of PDF exports were completed.
              minimum: 0
              example: 2
            failure:
              type: integer
              description: The number of PDF exports couldn't be exported.
              minimum: 0
              example: 0
            total:
              type: integer
              description: Total number of Quip threads to export to PDF.
              minimum: 0
              example: 2
        outputs:
          description: 'Array of exported their PDF URLs and statuses:

            '
          additionalProperties:
            x-additionalPropertiesName: thread_id
            type: object
            description: 'Identifier of the Quip thread for which you requested a
              PDF:

              '
            properties:
              pdf_url:
                type: string
                description: 'URL where you can access your PDF of the exported Quip

                  thread. The PDF is available for download at this URL for 3

                  days after the PDF is created.

                  '
                example: https://corp.quip.com/-/blob/RHE9AANz1Io/3aXoBEvHxahzUtBse0799g?name=RHE9AANz1lo.pdf&is_admin=true
              status:
                type: string
                enum:
                - PROCESSING
                - SUCCESS
                - FAILURE
                description: 'The status of your request. Possible statuses are:

                  * `PROCESSING`: The PDF export is in progress.

                  * `SUCCESS`: The PDF export was completed.

                  * `FAILURE`: The PDF couldn''t be exported. Call the

                  [Create Bulk Export PDF Request](

                  #operation/createBulkExportPdfsRequest) API method again to

                  create the PDF.

                  '
                example: SUCCESS
              message:
                type: string
                description: 'A message is returned if the status is FAILURE. It provides

                  information about what went wrong.

                  '
            required:
            - status
    get_export_pdf_response:
      type: object
      properties:
        pdf_url:
          type: string
          description: 'A URL where you can access your PDF of the exported Quip thread.

            It is returned if the status is `SUCCESS`. The PDF is available for

            download at this URL for 3 days after the PDF is created.

            '
          example: https://corp.quip.com/-/blob/RHE9AANz1Io/3aXoBEvHxahzUtBse0799g?name=RHE9AANz1lo.pdf
        status:
          type: string
          enum:
          - PROCESSING
          - SUCCESS
          - PARTIAL_SUCCESS
          - FAILURE
          description: 'The status of your request. Possible statuses are:

            * `PROCESSING`: The PDF export is in progress.

            * `SUCCESS`: The PDF export was completed. If you made a request to

            attach the PDF to a Quip document or Salesforce record, the PDF is

            also available in your specified location.

            * `PARTIAL_SUCCESS`: The PDF URL is available. However, the file

            couldn''t be attached in your specified location. Call the [Create

            Export PDF Request](#operation/createExportThreadToPdfRequest) API

            method again to attach the PDF to your specified Quip document or

            Salesforce record. Confirm that you passed in the correct

            `destination_thread_id`, `salesforce_org_id`, or

            `salesforce_record_id`.

            * `FAILURE`: The PDF couldn''t be exported. Call the [Create Export

            PDF Request](#operation/createExportThreadToPdfRequest) API method

            again to create the PDF.

            '
          example: SUCCESS
        message:
          type: string
          description: 'A message is returned if the status is `FAILURE` or

            `PARTIAL_SUCCESS`. It provides information about what

            went wrong.

            '
      required:
      - status
    mark_as_moved_to_external_request:
      type: object
      properties:
        thread_id:
          type: string
          description: 'The ID or secret path of the thread whose document you want
            to edit:

            - <b>ID</b>: You can find this in the `id` response field of the

            <a href=https://quip.com/dev/automation/documentation/current#get-thread>

            Get Thread </a> API method.

            - <b>secret path</b>: You can find this in the URL of a thread.

            For example, in this URL:

            "https://quip.com/3fs7B2leat8/TrackingDocument", the secret path

            is <b>3fs7B2leat8</b>.

            '
        status:
          description: Status of moving the thread to an external location.
          type: string
          enum:
          - unset
          - moving
          - moved
        url:
          type: string
          description: 'The url of the thread''s new off-Quip location. Should only
            be

            provided if the status is "moved", in which case it is required.

            '
      required:
      - thread_id
      - status
    mark_as_moved_to_external_response:
      type: object
      properties:
        thread_id:
          type: string
        status:
          description: Status of moving the thread to an external location.
          type: string
          enum:
          - unset
          - moving
          - moved
        url:
          type: string
          description: The url of the thread's new off-Quip location.
        user_id:
          type: string
          description: The ID of the user who updated the movement data.
        updated_usec:
          description: 'The [Unix timestamp](https://www.epochconverter.com/)

            in microseconds for when the movement data was last changed.

            '
      required:
      - thread_id
      - status
      - user_id
      - updated_usec
    user_info:
      allOf:
      - $ref: '#/components/schemas/user_info_without_folders'
      - $ref: '#/components/schemas/user_folders'
    user_info_without_folders:
      type: object
      properties:
        id:
          type: string
          description: ID of the user.
          example: UTUAEAiZl6B
        name:
          type: string
          description: Full name of the user.
          example: Jane Doe
        company_id:
          type: string
          description: ID of the user's company.
          example: IMbAcASGu56
        emails:
          type: array
          description: List of the user's emails.
          items:
            type: string
          example:
          - jane@example1.com
          - jane@example2.com
        disabled:
          type: boolean
          description: If `true`, the user has been disabled.
          example: false
        created_usec:
          type: integer
          format: int64
          description: 'Timestamp (in microseconds since UNIX epoch) the user was
            created.

            '
          example: 1632022665732239
        is_robot:
          type: boolean
          description: If `true`, the user is a bot user.
          example: false
        affinity:
          type: number
          format: double
          description: "A floating point number between 0 and 1 indicating the authenticated\n\
            \ user's affinity to this user. Quip generally presents contacts in\n\
            \ affinity order throughout the app.\n"
          example: 0.43
        chat_thread_id:
          type: string
          description: 'The ID of the chat thread between the authenticated user and
            this

            user, if any.

            '
          example: adHAAAKik9A
        profile_picture_url:
          type: string
          description: URL of the user's profile picture.
          example: https://acme.quip.com:443/vWMeAXtnYvRMJJH_A6OaMA
      required:
      - id
      - name
      - is_robot
      - affinity
    user_folders:
      type: object
      properties:
        desktop_folder_id:
          type: string
          description: The ID of the user's desktop folder.
          example: AGWAOAhT3qk
        archive_folder_id:
          type: string
          description: The ID of the user's archive folder.
          example: BGWAOAhT3qk
        starred_folder_id:
          type: string
          description: The ID of the user's starred folder.
          example: CGWAOAhT3qk
        private_folder_id:
          type: string
          description: The ID of the user's private folder.
          example: DGWAOAhT3qk
        trash_folder_id:
          type: string
          description: The ID of the user's trash folder.
          example: EGWAOAhT3qk
        shared_folder_ids:
          type: array
          description: The IDs of the user's shared folders.
          items:
            type: string
          minimum: 0
          example:
          - FGWAOAhT3qk
          - GGWAOAhT3qk
        group_folder_ids:
          type: array
          description: The IDs of the user's group folders.
          items:
            type: string
          minimum: 0
          example:
          - HGWAOAhT3qk
          - IGWAOAhT3qk
    user_not_found_err_property:
      type: object
      properties:
        error:
          type: string
          description: 'An error message describing why the user could not be found.

            '
    user_contacts:
      type: array
      items:
        allOf:
        - $ref: '#/components/schemas/user_info_without_folders'
        - $ref: '#/components/schemas/user_not_found_err_property'
    user_info_v2:
      allOf:
      - $ref: '#/components/schemas/user_info_without_folders_v2'
      - $ref: '#/components/schemas/user_folders_v2'
    user_info_without_folders_v2:
      type: object
      properties:
        id:
          type: string
          description: ID of the user.
          example: UTUAEAiZl6B
        name:
          type: string
          description: Full name of the user.
          example: Jane Doe
        company_id:
          type: string
          description: ID of the company that the user works for.
          example: IMbAcASGu56
        emails:
          type: array
          description: List of the user's emails.
          items:
            type: string
          example:
          - jane@example1.com
          - jane@example2.com
        disabled:
          type: boolean
          description: 'Returns `true` if the user has been deactivated. Returns `false`

            if the user is enabled.

            '
          example: false
        created_usec:
          type: integer
          format: int64
          description: 'The [Unix timestamp](https://www.epochconverter.com) in

            microseconds for when the user''s account was created.

            '
          example: 1632022665732239
        is_robot:
          type: boolean
          description: If `true`, the user is a bot user.
          example: false
        affinity:
          type: number
          format: double
          description: 'A number between 0 and 1 indicating the frequency and recency
            of

            messages exchanged between the user calling this API method and

            the specified user.

            '
          example: 0.43
        chat_thread_id:
          type: string
          description: 'The ID of the chat thread between the authenticated user and
            this

            user, if any.

            '
          example: adHAAAKik9A
        profile_picture_url:
          type: string
          description: URL where the user's profile picture is located.
          example: https://acme.quip.com:443/vWMeAXtnYvRMJJH_A6OaMA
      required:
      - id
      - name
      - is_robot
      - affinity
    user_folders_v2:
      type: object
      properties:
        desktop_folder_id:
          type: string
          description: 'The ID of the user''s desktop folder. The desktop folder is
            a

            legacy folder that''s no longer visible in the UI.

            '
          example: AGWAOAhT3qk
        archive_folder_id:
          type: string
          description: 'The ID of the user''s archive folder. The archive folder is
            a

            legacy folder that''s no longer visible in the UI.

            '
          example: BGWAOAhT3qk
        starred_folder_id:
          type: string
          description: The ID of the user's starred folder.
          example: CGWAOAhT3qk
        private_folder_id:
          type: string
          description: The ID of the user's private folder.
          example: DGWAOAhT3qk
        trash_folder_id:
          type: string
          description: The ID of the user's trash folder.
          example: EGWAOAhT3qk
        shared_folder_ids:
          type: array
          description: 'The IDs of the folders that the user shared with other members.

            '
          items:
            type: string
          minimum: 0
          example:
          - FGWAOAhT3qk
          - GGWAOAhT3qk
        group_folder_ids:
          type: array
          description: 'The IDs of the group folders that the user is a member of.

            '
          items:
            type: string
          minimum: 0
          example:
          - HGWAOAhT3qk
          - IGWAOAhT3qk
    user_threads:
      type: object
      properties:
        threads:
          description: 'Information about a thread. The fields returned are:

            '
          additionalProperties:
            x-additionalPropertiesName: thread_id
            type: object
            description: 'This is the `thread_id`, which is the unique identifier
              for a

              thread.

              '
        response_metadata:
          allOf:
          - $ref: '#/components/schemas/response_metadata'
      required:
      - threads
    user_threads_meta:
      type: object
      properties:
        threads:
          description: 'Information about a thread. The fields returned are:

            '
          additionalProperties:
            x-additionalPropertiesName: thread_id
            type: object
            description: 'This is the `thread_id`, which is the unique identifier
              for a

              thread.

              '
            properties:
              updated_usec:
                type: integer
                format: int64
                description: 'The [Unix timestamp](https://www.epochconverter.com)
                  in

                  microseconds for when the thread was last updated.

                  '
                example: 1631915313977048
              is_deleted:
                type: boolean
                description: 'Returns `true` if the thread is deleted. Returns `false`
                  if

                  this thread isn''t deleted.

                  '
                example: false
              link:
                type: string
                description: Permalink for the thread.
                example: https://example.com/KbTAAAkz5h7
              thread_type:
                type: string
                description: 'The type of the thread.

                  '
                enum:
                - TEXT_DOCUMENT
                - SPREADSHEET_DOCUMENT
                - SLIDES
                - CHAT
                - OTHER
                example: TEXT_DOCUMENT
        response_metadata:
          allOf:
          - $ref: '#/components/schemas/response_metadata'
      required:
      - threads
    base_error_response:
      description: General purpose error response
      type: object
      properties:
        error:
          description: General category of error.
          type: string
        error_code:
          type: integer
        error_description:
          description: 'Human-readable description of API error case, if available.

            '
          type: string
    error_response:
      allOf:
      - $ref: '#/components/schemas/base_error_response'
      - properties:
          error_code:
            description: HTTP status code of this response.
    response_metadata:
      type: object
      properties:
        next_cursor:
          type: string
          description: 'If more data is available, this field returns a cursor value
            that

            points to the next page of data you can get. Pass this value into

            the `cursor` field in your next call to retrieve more data. If no

            additional data is available, this field is empty. Continue to call

            this API method with each new cursor value until this field returns

            empty.


            <b>Note</b>: Each `next_cursor` value returned by this API method

            expires 30 minutes after creation. After a cursor expires, you can

            call this API again to get a new cursor.

            '
          example: Y3Vyc29yVG9OZXh0UGFnZQ==
  responses:
    thread_edit_share_link_response:
      description: 'An object with the thread''s ID as its only property and the string

        "success" as its value.

        '
      content:
        application/json:
          schema:
            type: object
            additionalProperties:
              x-additionalPropertiesName: thread_id
              type: string
              enum:
              - success
    200_docx:
      description: Successful Response
      content:
        application/vnd.openxmlformats-officedocument.wordprocessingml.document:
          schema:
            description: The DOCX content returned in the response body.
            type: string
            format: binary
    400_add_thread_to_folders_v2:
      description: Bad Request
      content:
        application/json:
          schema:
            allOf:
            - properties:
                error_code:
                  type: integer
                  default: 400
                error:
                  description: Bad Request
                  type: string
                error_description:
                  description: 'A required input is missing or your request is over
                    a specified limit. Check the reference documentation for the required
                    inputs and any limits.

                    '
                  type: string
    403_add_thread_to_folders_v2:
      description: Forbidden
      content:
        application/json:
          schema:
            allOf:
            - properties:
                error_code:
                  type: integer
                  default: 403
                error:
                  description: Forbidden
                  type: string
                error_description:
                  description: 'The caller doesn''t have full access to the thread.
                    Contact the thread owner to request full (own) access to it.

                    '
                  type: string
    404_add_thread_to_folders_v2:
      description: Not Found
      content:
        application/json:
          schema:
            allOf:
            - properties:
                error_code:
                  type: integer
                  default: 404
                error:
                  description: Not Found
                  type: string
                error_description:
                  description: 'The thread identifier wasn''t found. Confirm that
                    you passed in the correct thread identifier and the associated
                    thread exists and isn''t deleted.

                    '
                  type: string
    400_get_users_v2:
      description: Bad Request
      content:
        application/json:
          schema:
            allOf:
            - properties:
                error_code:
                  type: integer
                  default: 400
                error:
                  description: Bad Request
                  type: string
                error_description:
                  description: "We couldn't complete the request. Confirm that you:\n\
                    - Passed in the correct identifier for the data that you\n  want\
                    \ to view, add, copy, edit, or delete and the\n  associated data\
                    \ exists.\n- Provided all required inputs, only allowable values,\n\
                    \  and a supported combination of inputs as described\n  in the\
                    \ reference documentation.\n- Made a request for a thread whose\
                    \ content isn't locked\n  or on which editing is disabled.\n-\
                    \ Passed in data using valid syntax such as correct JSON,\n  Markdown,\
                    \ or HTML syntax.\n"
                  type: string
    403_get_users_v2:
      description: Forbidden
      content:
        application/json:
          schema:
            allOf:
            - properties:
                error_code:
                  type: integer
                  default: 403
                error:
                  description: Forbidden
                  type: string
                error_description:
                  description: 'The user making the call doesn''t have the required
                    access to the thread or user. Contact the Quip admin or thread
                    owner to request access.

                    '
                  type: string
    404_get_users_v2:
      description: Not Found
      content:
        application/json:
          schema:
            allOf:
            - properties:
                error_code:
                  type: integer
                  default: 404
                error:
                  description: Not Found
                  type: string
                error_description:
                  description: 'Invalid `section_id`, `thread_id`, or `id`. Confirm
                    that you passed in the correct ID and the associated item or user
                    exists.

                    '
                  type: string
    304_not_modified:
      description: Not Modified
      content:
        application/json:
          schema:
            allOf:
            - $ref: '#/components/schemas/error_response'
            - properties:
                error_code:
                  default: 304
    400_bad_request:
      description: Bad Request
      content:
        application/json:
          schema:
            allOf:
            - $ref: '#/components/schemas/error_response'
            - properties:
                error_code:
                  default: 400
    401_authentication:
      description: Authentication Error
      content:
        application/json:
          schema:
            allOf:
            - $ref: '#/components/schemas/error_response'
            - properties:
                error_code:
                  default: 401
    403_forbidden:
      description: Forbidden
      content:
        application/json:
          schema:
            allOf:
            - $ref: '#/components/schemas/error_response'
            - properties:
                error_code:
                  default: 403
    404_not_found:
      description: Not Found
      content:
        application/json:
          schema:
            allOf:
            - $ref: '#/components/schemas/error_response'
            - properties:
                error_code:
                  default: 404
    413_payload_too_large:
      description: Payload Too Large
      content:
        application/json:
          schema:
            allOf:
            - $ref: '#/components/schemas/error_response'
            - properties:
                error_code:
                  default: 413
    429_too_many_requests:
      description: Too Many Requests
      content:
        application/json:
          schema:
            allOf:
            - $ref: '#/components/schemas/error_response'
            - properties:
                error_code:
                  default: 429
    500_server_error:
      description: Server Error
      content:
        application/json:
          schema:
            allOf:
            - $ref: '#/components/schemas/error_response'
            - properties:
                error_code:
                  default: 500
    503_service_unavailable:
      description: Service Unavailable
      content:
        application/json:
          schema:
            allOf:
            - $ref: '#/components/schemas/error_response'
            - properties:
                error_code:
                  default: 503
    503_rate_limit:
      description: Rate Limited
      content:
        application/json:
          schema:
            allOf:
            - $ref: '#/components/schemas/error_response'
            - properties:
                error_code:
                  default: 503
    504_gateway_timeout:
      description: Service Unavailable
      content:
        application/json:
          schema:
            allOf:
            - $ref: '#/components/schemas/error_response'
            - properties:
                error_code:
                  default: 504
    401_authentication_v2:
      description: Authentication Error
      content:
        application/json:
          schema:
            allOf:
            - properties:
                error_code:
                  type: integer
                  default: 401
                error:
                  description: Authentication Error
                  type: string
                error_description:
                  description: 'The access token is invalid or missing. Confirm that
                    your request header contains a valid access token. Then call the
                    API method again.

                    '
                  type: string
    500_server_error_v2:
      description: Server Error
      content:
        application/json:
          schema:
            allOf:
            - properties:
                error_code:
                  type: integer
                  default: 500
                error:
                  description: Server Error
                  type: string
                error_description:
                  description: 'We couldn''t complete the request. Try again later.
                    If this error reoccurs, contact Quip Support.

                    '
                  type: string
paths:
  /1/oauth/access_token:
    post:
      tags:
      - Authentication
      summary: Token Endpoint
      operationId: accessToken
      description: 'After you have obtained a verification code or refresh token,
        you can

        exchange it for an access token via a POST request to this

        endpoint.

        '
      parameters:
      - name: grant_type
        in: query
        schema:
          type: string
          enum:
          - refresh_token
          - authorization_code
        description: Either `refresh_token` or `authorization_code`.
        required: true
      - name: client_id
        in: query
        schema:
          type: string
        required: true
        description: The client ID you created for your application.
      - name: client_secret
        in: query
        schema:
          type: string
        required: true
        description: The client secret you created for your application.
      - name: refresh_token
        in: query
        schema:
          type: string
        description: Required if `grant_type` is `refresh_token`.
      - name: code
        in: query
        schema:
          type: string
        description: Required if `grant_type` is `authorization_code`.
      - name: redirect_uri
        in: query
        schema:
          type: string
        description: 'Required if `grant_type` is `authorization_code`. Must match
          the `redirect_uri` supplied when requesting that authorization code.

          '
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  access_token:
                    description: Token that can be used to access Quip APIs
                    type: string
                  expires_in:
                    description: Number of seconds until token expires.
                    type: integer
                    format: int32
                  refresh_token:
                    description: 'Token that can be used to obtain another access
                      token in the future.

                      '
                    type: string
                  scope:
                    description: 'Space-separated list of authorization scopes that
                      can be accessed via this token.

                      '
                    type: string
                  token_type:
                    description: Type of this token.
                    type: string
                    enum:
                    - Bearer
                required:
                - access_token
                - expires_in
                - refresh_token
                - scope
                - token_type
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/oauth/login:
    get:
      tags:
      - Authentication
      summary: Authorization Endpoint
      operationId: authorization
      description: 'Redirect end users to this URL to get an OAuth 2.0 verification
        code,

        which you can exchange for an access token.

        '
      parameters:
      - name: client_id
        in: query
        schema:
          type: string
        required: true
        description: 'The client ID you

          [created](https://corp.quip.com/api/domain-tokens)

          for your application.

          '
      - name: client_secret
        in: query
        schema:
          type: string
        required: true
        description: The client secret you created for your application.
      - name: redirect_uri
        in: query
        schema:
          type: string
        required: true
        description: 'The URL we should redirect back to with the verification code.

          '
        example: https://app.postman.com/oauth2/callback
      - name: state
        in: query
        schema:
          type: integer
        description: 'If given, we include this argument in our redirect back to the

          redirect_uri. This is recommended to prevent a variety of

          security issues.

          '
        example: 1234
      responses:
        '302':
          description: Successful response
          headers:
            Location:
              schema:
                type: string
              description: 'The URL to redirect to. Same as the URL returned in the
                body.

                '
          content:
            text/plain; charset=utf-8:
              schema:
                type: string
                description: 'The URL to redirect to. Same as the URL returned in
                  the

                  `Location` header.

                  '
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/oauth/revoke:
    post:
      tags:
      - Authentication
      summary: Revoke a Token
      operationId: revokeToken
      description: 'Revoke an `access_token` or a `refresh_token`.

        '
      parameters:
      - name: client_id
        in: query
        schema:
          type: string
        required: true
        description: The client ID you created for your application.
      - name: client_secret
        in: query
        schema:
          type: string
        required: true
        description: The client secret you created for your application.
      - name: token
        in: query
        schema:
          type: string
        required: true
        description: The token to revoke.
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                description: Empty JSON object
                type: object
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/oauth/verify_token:
    get:
      tags:
      - Authentication
      summary: Verify Token
      operationId: verifyToken
      description: Verifies the validity of the `access_token` in your header.
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  expires_in:
                    type: integer
                    format: int32
                    description: Number of seconds until token expires.
                    example: 2425690
                  scope:
                    type: string
                    description: 'Space-separated list of authorization scopes that
                      can

                      be accessed via this token.

                      '
                    example: USER_MANAGE USER_WRITE USER_READ
                  token_type:
                    type: string
                    enum:
                    - Bearer
                    description: Type of this token. Will always be "Bearer".
                  client_id:
                    type: string
                    description: 'The `client_id` of the API key that was used to
                      generate

                      this access token if applicable.

                      '
                  api_key_expires_in:
                    type: integer
                    format: int32
                    description: 'Number of seconds until the API key used to mint

                      this access token expires.

                      '
                    example: 2425690
                required:
                - expires_in
                - scope
                - token_type
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/threads/add-members:
    post:
      security:
      - OAuth2:
        - USER_MANAGE
      tags:
      - Threads
      summary: Add People to a Thread or Add a Thread to Folders
      operationId: addMembersToThreadOrAddThreadToFolders
      description: "Shares a Quip thread (document, spreadsheet, or chat) with specified\n\
        people (members) at your company and adds the thread to folders.\nThis supports\
        \ information-sharing and collaboration within and\nacross teams.\n\n**Note:**\n\
        \n  * You can add a maximum of 100 people to a thread per request\n    and\
        \ 2,500 people per thread across multiple requests.\n  * You can add a thread\
        \ to a maximum of 100 folders per request\n    and 2,500 folders across multiple\
        \ requests.\n\nSee also: [Share Documents and Folders](\n    https://help.salesforce.com/s/articleView?id=000354975&type=1)\n\
        \n### Sample Calls\nIn this example, four people are added to a thread with\
        \ the ID\n**e3fs7B2leat8**. The users are added with these access levels:\n\
        \n* **0**: Full access\n* **1**: Edit\n* **2**: Comment\n* **3**: View\n\n\
        See the reference documentation for more information about the access\nlevels.\n\
        \n```text\nPOST https://platform.quip.com/1/threads/add-members\nContent-Type:\
        \ application/json\nAuthorization: Bearer {{ABCSampleAccessToken}}\n\n{\n\
        \    \"thread_id\": \"e3fs7B2leat8\",\n    \"member_ids_by_access_level\u201D\
        :\n        [\n            {\"access_level\": 0, \"member_ids\": [\"ABC12341234\"\
        ]},\n            {\"access_level\": 1, \"member_ids\": [\"DEF45456789\"]},\n\
        \            {\"access_level\": 2, \"member_ids\": [\"LMN74856789\"]},\n \
        \           {\"access_level\": 3, \"member_ids\": [\"XYZEF454599\"]}\n   \
        \     ]\n    }\n}\n```\n\nIn this example, two actions are taken on a thread\
        \ with ID\n**e3fs7B2leat8**:\n\n1. Add it to a folder with ID **abCsOFj2Ny3a**.\n\
        2. Add a member with user ID **XYZJAEAck4vn** to the thread.\n\n```text\n\
        POST https://platform.quip.com/1/threads/add-members\nContent-Type: application/json\n\
        Authorization: Bearer {{ABCSampleAccessToken}}\n{\n    \"thread_id\": \"e3fs7B2leat8\"\
        ,\n    \"member_ids\": {\"abCsOFj2Ny3a\",\"XYZJAEAck4vn\"}\n}\n```\n"
      requestBody:
        content:
          application/x-www-form-urlencoded:
            schema:
              $ref: '#/components/schemas/thread_add_members_v1_request'
      parameters:
      - name: Content-Type
        in: header
        schema:
          type: string
        example: application/x-www-form-urlencoded
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/thread_info_v1'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/threads/add-rows: {}
  /1/threads/copy-document:
    post:
      security:
      - OAuth2:
        - USER_READ
        - USER_WRITE
      tags:
      - Threads
      summary: Copy a Document or Template
      operationId: copyDocument
      description: "Makes a copy of a thread (Quip document, spreadsheet, or template).\n\
        This API method allows you to easily reuse existing content,\nautomatically\
        \ add members to the thread, and add the thread to a\nfolder. For example,\
        \ after a predefined step is completed, you can\nmake a copy of a template\
        \ and fill it in with your specified content.\n\n**Note:** Quip has introduced\
        \ a faster, more scalable version of this\nAPI method: [Copy a Document or\
        \ Template V2](\nhttps://quip.com/dev/automation/documentation/current#operation/copyDocumentV2\n\
        ). You\u2019re encouraged to modify your integrations to point to the\nlatest\
        \ versions of API methods. You can continue to access legacy\nversions of\
        \ API methods until we announce when support for them ends.\n\nSee also: [Folders\
        \ (Quip)](\n  https://help.salesforce.com/s/articleView?id=000355165&type=1),\n\
        \  [REST API Versioning FAQ](\n  https://quip.com/dev/automation/documentation/current#section/FAQs/REST-API-Versioning-FAQ)\n\
        \n### Sample Call\nIn this example, a template with ID <b>e3fs7B2leat8</b>\
        \ is copied and\nthe new document is filled in based on the data in the values\
        \ field.\nThe new thread is also added to a folder with ID <b>N5aaOTih0VYy</b>.\n\
        \n```text\nPOST https://platform.quip.com/1/threads/copy-document\nContent-Type:\
        \ application/json\nAuthorization: Bearer ABCSampleAccessToken\n\n{\n    \"\
        thread_id\": \"e3fs7B2leat8\",\n    \"title\": \"Customer Welcome\",\n   \
        \ \"folder_ids\": \"N5aaOTih0VYy\",\n    \"values\": \"{\n        \"Customer\"\
        : {\"Age\": 34, \"Name\": \"Arnie\"},\n        \"Greeting\": \"Hello\"\n \
        \   }\",\n    \"copy_annotations\": \"false\"\n}\n```\n"
      requestBody:
        content:
          application/x-www-form-urlencoded:
            schema:
              $ref: '#/components/schemas/copy_document_v1_request'
      parameters:
      - name: Content-Type
        in: header
        schema:
          type: string
        example: application/x-www-form-urlencoded
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/thread_info_v1'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /2/threads/{threadIdOrSecretPath}/copy:
    post:
      security:
      - OAuth2:
        - USER_READ
        - USER_WRITE
      tags:
      - Threads
      summary: Copy a Document or Template V2
      operationId: copyDocumentV2
      description: Makes a copy of a Quip thread (document, spreadsheet, or template)
        and adds it to a folder. This API method allows you to easily reuse existing
        content. For example, after a predefined step is completed, copy a template
        and add your specified content. When you add the new thread to a folder, members
        can automatically access that thread. This supports information-sharing and
        collaboration within and across teams.
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/copy_document_v2_request'
      parameters:
      - $ref: '#/components/parameters/thread_id_or_secret_path'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/thread_get_v2'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '429':
          $ref: '#/components/responses/429_too_many_requests'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/threads/delete:
    post:
      security:
      - OAuth2:
        - USER_MANAGE
      tags:
      - Threads
      summary: Delete a Thread
      operationId: deleteThread
      description: 'Deletes the thread with the specified ID or secret.

        '
      requestBody:
        content:
          application/x-www-form-urlencoded:
            schema:
              $ref: '#/components/schemas/thread_delete_request'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                description: Empty JSON object.
                type: object
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/threads/edit-document:
    post:
      security:
      - OAuth2:
        - USER_READ
        - USER_WRITE
      tags:
      - Threads
      summary: Edit a Document
      operationId: editDocument
      description: "Modifies the content of a thread (Quip document or spreadsheet).\n\
        This API method allows you to mix and match content from different\nsources\
        \ and automatically add it to the same thread whenever new\ndata becomes available.\
        \ Quip users can then collaborate on the\nthread or make any other changes\
        \ to it. Sample content:\nproject status updates, meeting minutes, support\
        \ cases, event\nregistrations, approvals, survey results, or payments.\n\n\
        ### Note\n- <b>Live apps</b>:\n  - You can add only these types of live apps\
        \ to a document:\n    calendar, Salesforce record, Salesforce list, Kanban\
        \ board,\n    and project tracker.\n- <b>Spreadsheets</b>:\n  - You can add\
        \ a row or edit a cell in a spreadsheet embedded in a\n    Quip document or\
        \ a standalone Quip spreadsheet.\n  - The number of columns that you pass\
        \ into your API call must be\n    less than or equal to the number of columns\
        \ in the spreadsheet.\n    Any extra columns you pass in aren't added.\n \
        \ - Quip allows you to add a maximum of 100,000 cells to a\n    spreadsheet.\
        \ This means that you can add a maximum of 100,000\n    cells by calling this\
        \ API method once or multiple times.\n  - You can add a maximum of 1,000 rows\
        \ with each API call.\n  - For best performance, it's recommended that you\
        \ limit the number\n    of cells you add to a maximum of 30,000 for each spreadsheet.\n\
        - <b>Paragraphs</b>:\n  - You can't edit only a sentence in a paragraph. To\
        \ edit a\n    sentence, replace the paragraph it's in with new content.\n\
        \  - Deleting a sentence in a paragraph deletes the whole paragraph.\n"
      requestBody:
        content:
          application/x-www-form-urlencoded:
            schema:
              $ref: '#/components/schemas/edit_document_request'
      parameters:
      - name: Content-Type
        in: header
        schema:
          type: string
        example: application/x-www-form-urlencoded
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/edit_document_response'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '413':
          $ref: '#/components/responses/413_payload_too_large'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/threads/edit-share-link-settings:
    post:
      security:
      - OAuth2:
        - USER_MANAGE
      tags:
      - Threads
      summary: Edit Thread Link Share Settings
      operationId: editThreadLinkShareSettings
      description: "Changes share link settings on a thread.\n\n\nAt least one of\
        \ the following must be included in the request:\n * `allow_external_access`\n\
        \ * `mode`\n * `enable_request_access`\n * `show_conversation`\n * `show_edit_history`\n\
        \ * `allow_messages`\n * `allow_comments`\n"
      requestBody:
        content:
          application/x-www-form-urlencoded:
            schema:
              $ref: '#/components/schemas/thread_edit_share_link_request'
      responses:
        '200':
          $ref: '#/components/responses/thread_edit_share_link_response'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/threads/{thread_id}/export/docx:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Threads
      summary: Export Document to .docx
      operationId: exportThreadToDocx
      description: Exports your specified Quip document to a DOCX file.
      parameters:
      - name: thread_id
        in: path
        schema:
          type: string
        required: true
        description: 'The ID or secret path of the thread for the document you want
          to

          export.

          '
      responses:
        '200':
          $ref: '#/components/responses/200_docx'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/threads/export/async:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Threads
      summary: Retrieve Bulk Export Response
      operationId: getBulkExportResponse
      description: 'Returns the statuses and doc URLs after a request you made to
        export

        multiple Quip documents using the [Create Bulk Export

        Request](#operation/createBulkExportRequest) API method. You can

        export multiple Quip documents to fulfill eDiscovery and other

        regulatory requirements and archive documents in other systems. You

        can also use one of your other systems to search all document data,

        including comments, and export the matching results.

        '
      parameters:
      - name: request_id
        in: query
        schema:
          type: string
        required: true
        description: 'Identifier returned by the [Create Bulk Export Request](

          #operation/createBulkExportRequest) API method.

          '
        example: AMXAEA8lSEj:1644470492776
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/get_bulk_export_response'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
    post:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Threads
      summary: Create Bulk Export Request
      operationId: createBulkExportRequest
      description: 'This endpoint is currently available only to select customers.
        Please

        contact Quip support for more information.


        Submits a request to asynchronously export multiple Quip documents.

        This call returns a `request_id`. Pass that `request_id` into the

        [Retrieve Bulk Export Response](

        #operation/getBulkExportResponse) call to get the doc URL and

        request status for each doc.


        Sample use cases: You can export documents to fulfill

        eDiscovery and other regulatory requirements and archive documents

        in other systems. You can also use one of your other systems to

        search all document data, including comments, and export the

        matching results.


        Note:

        - The appearance of the format(docx/xlsx/pdf) created using this

        API method is typically the same as documents exported in the Quip

        application. Sometimes there are minor formatting variations when you

        export via API. Example: fonts sometimes look different in a PDF

        exported via API.

        - Charts in spreadsheets are excluded from the exported PDF.

        - This API is subject to rate limiting. See [Document Bulk Export

        Rate Limit](#section/Rate-Limits/Document-Bulk-Export-Rate-Limit)

        for details.

        '
      parameters:
      - name: Content-Type
        in: header
        schema:
          type: string
        example: application/json
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                threads:
                  type: array
                  items:
                    type: object
                    properties:
                      thread_id:
                        type: string
                        description: 'The ID of the thread for the

                          document or spreadsheet you want to export.

                          '
                      format:
                        type: string
                        enum:
                        - XLSX
                        - DOCX
                        - PDF
                        description: 'The format you want to export this quip document
                          to.

                          '
                        example: PDF
                  description: 'A list of objects with `thread_id` and `format`. Each

                    document can have its own format you want to export to.

                    '
                  example:
                  - thread_id: UcZ9AAhvqrc
                    format: XLSX
                  - thread_id: AVN9AAeqq5w
                    format: DOCX
                include_conversations:
                  type: boolean
                  default: false
                  description: 'Determines whether to include the conversation history

                    associated with each Quip document or spreadsheet that you

                    want to export. The formats supporting conversation

                    history are PDF, DOCX, XLSX. Allowable values for this

                    field:

                    * `true`: Include the conversation history.

                    * `false`: Don''t include the conversation history.

                    '
                  example: true
                omit_if_unchanged_since_usec:
                  type: integer
                  description: 'This is Unix timestamp in microseconds. It determines

                    whether to omit a quip document or spreadsheet if it is

                    unchanged since this timestamp. If this field is

                    unprovided, all documents listed in the `threads` field

                    will be exported.

                    '
                  example: 1750375408000000
                locale:
                  type: string
                  default: en-US
                  description: 'The preferred locale (e.g., en-US, fr-CA) used in

                    exporting documents.

                    '
              required:
              - threads
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  request_id:
                    type: string
                    description: 'Identifier that you can pass into the Retrieve Bulk

                      Export Response call to get the doc URL and request

                      status for each doc.

                      '
                    example: AMXAEA8lSEj:1644470492776
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '429':
          $ref: '#/components/responses/429_too_many_requests'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/threads/{thread_id}/export/pdf:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Threads
      summary: Export Slides to .pdf
      operationId: exportThreadToPdf
      description: Exports your specified Quip slide deck to PDF.
      parameters:
      - name: thread_id
        in: path
        schema:
          type: string
        required: true
        description: 'The ID or secret path of the thread for the document you want
          to

          export.

          '
      responses:
        '200':
          description: Successful Response
          content:
            application/pdf:
              schema:
                description: The PDF content returned in the response body.
                type: string
                format: binary
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/threads/{thread_id}/export/pdf/async:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Threads
      summary: Retrieve Export PDF Response
      operationId: getExportPdfResponse
      description: 'Returns the status and PDF URL after a request you made to export
        a

        Quip document or Quip spreadsheet to PDF using the [Create Export PDF

        Request](#operation/createExportThreadToPdfRequest) API method.

        You can use the PDF to mark an approval cycle as complete, take a

        record-keeping snapshot, or share information with your leadership or

        with customers.


        Note:

        - Depending on the size of a thread, it can take up to 10 minutes

        to complete the PDF export. If you call the Retrieve Export PDF

        - Response API method and your PDF isn''t available, wait a few minutes

        then make the call again.

        '
      parameters:
      - name: request_id
        in: query
        schema:
          type: string
        required: true
        description: 'ID returned by the [Create Export PDF Request]( #operation/createExportThreadToPdfRequest)
          API method. Use this value to get the status and PDF URL after calling the
          [Create Export PDF Request](#operation/createExportThreadToPdfRequest) API
          method.'
      - name: thread_id
        in: path
        schema:
          type: string
        required: true
        description: 'ID of the thread whose document you requested a PDF export for
          using the [Create Export PDF Request]( #operation/createExportThreadToPdfRequest)
          API method.'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/get_export_pdf_response'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
    post:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Threads
      summary: Create Export PDF Request
      operationId: createExportThreadToPdfRequest
      description: "Submits a request to asynchronously export a Quip document or\
        \ Quip\nspreadsheet to PDF. This call returns a `request_id`. Pass that\n\
        `request_id` into the [Retrieve Export PDF Response](\n#operation/getExportPdfResponse)\
        \ call to get the PDF URL and request\nstatus. Sample use cases: You can export\
        \ a document or spreadsheet to\nPDF to mark an approval cycle as complete,\
        \ take a record-keeping\nsnapshot, or share the PDF with your leadership or\
        \ with customers.\n\nNote:\n  - Depending on the size of a thread, it can\
        \ take up to 10 minutes to\n  complete the PDF export. If you call the [Retrieve\
        \ Export PDF\n  Response](#operation/getExportPdfResponse) API method and\
        \ your PDF\n  isn't available, wait a few minutes then make the call again.\n\
        \n  - You can use this API method to complete a PDF export of a\n  standalone\
        \ Quip spreadsheet, not a spreadsheet inserted into a Quip\n  document. When\
        \ you do a PDF export of a Quip document containing a\n  spreadsheet, the\
        \ spreadsheet appears in the PDF.\n\n  - You can export a maximum of 40,000\
        \ cells in a spreadsheet to PDF.\n\n  - Charts in spreadsheets are excluded\
        \ from the exported PDF.\n\n  - The appearance of the PDF exported using this\
        \ API method is\n  typically the same as if you exported a document or spreadsheet\
        \ to\n  PDF in the Quip application. Sometimes there are differences when\n\
        \  you export via API. For example, in the PDF:\n    - Bullets look bigger.\n\
        \    - Emojis aren't displayed. They're replaced with boxes in the PDF.\n\
        \    - In large spreadsheets or spreadsheets that break across pages,\n  \
        \  some of the data is hidden.\n    - Live apps and graphics are distorted.\n\
        \    - Page breaks appear in the middle of content (such as a live\n    app)\
        \ that's supposed to be kept on the same page.\n    - Some Salesforce data\
        \ is hidden based on permissions set by the\n    Salesforce admin.\n"
      parameters:
      - name: thread_id
        in: path
        schema:
          type: string
        required: true
        description: ID of the Quip document or spreadsheet that you want to export
          to PDF.
      - name: destination_thread_id
        in: query
        schema:
          type: string
        description: ID of the Quip document to which you want to attach the exported
          PDF. The PDF gets attached to the end of your specified document.
      - name: salesforce_org_id
        in: query
        schema:
          type: string
        description: ID of the Salesforce organization in which you want to attach
          the exported PDF. If you pass in a `salesforce_org_id`, you must also pass
          in a `salesforce_record_id`.
      - name: salesforce_record_id
        in: query
        schema:
          type: string
        description: ID of the Salesforce record to which you want to attach the exported
          PDF. If you pass in a `salesforce_record_id`, you must also pass in a `salesforce_org_id`.
      - name: sheet_name
        in: query
        schema:
          type: string
        description: If you're exporting a spreadsheet with multiple tabs, this field
          identifies the tab that you want to export to PDF. If you don't identify
          the tab, the first tab is exported.
      - name: apply_print_options
        in: query
        schema:
          type: boolean
          default: false
        description: 'Determines whether to apply print options to the exported PDF.
          Allowable values are: * `true`: Apply these print options to the PDF: Include
          all headers and footers Show collapsed content Remove web formatting * `false`:
          Don''t apply print options to the PDF.'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  request_id:
                    type: string
                    description: 'ID that you can pass into the [Retrieve Export PDF

                      Response](#operation/getExportPdfResponse) call to get

                      the PDF URL and request status.

                      '
                    example: IAcAAAY7zCRAMXAEA8lSEj1644527357113
                  status:
                    type: string
                    enum:
                    - PROCESSING
                    description: 'The status of your request. Possible statuses are:

                      * `PROCESSING`: The PDF export is in progress.

                      '
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/threads/{thread_id}/export/xlsx:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Threads
      summary: Export Spreadsheet to .xlsx
      operationId: exportThreadToXlsx
      description: Exports your specified Quip spreadsheet to an XLSX file.
      parameters:
      - name: thread_id
        in: path
        schema:
          type: string
        required: true
        description: 'The ID or secret path of the thread for the document you want
          to

          export.

          '
      responses:
        '200':
          description: Successful Response
          content:
            application/vnd.openxmlformats-officedocument.spreadsheetml.sheet:
              schema:
                description: The XLSX content returned in the response body.
                type: string
                format: binary
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /2/threads/{threadIdOrSecretPath}/folders:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Threads
      summary: Get Thread Folders V2
      operationId: getThreadFoldersV2
      description: "Returns the list of folders that a Quip thread (document, spreadsheet,\n\
        \ or chat) is in. Use this API method to monitor\n information-sharing and\
        \ improve folder organization on your\n Quip site.\n"
      parameters:
      - $ref: '#/components/parameters/thread_id_or_secret_path_for_get'
      - $ref: '#/components/parameters/cursor'
      - $ref: '#/components/parameters/limit'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/thread_get_folders_v2_response'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/threads/{id}:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Threads
      deprecated: true
      summary: Get Thread
      operationId: getThread
      description: "Get information about a thread. You may also pass in a 12 character\n\
        URL suffix to get the permanent thread ID.\nIf Mirrored Salesforce Permissions\
        \ is enabled, data included in a\ndocument by using a Salesforce Data Mention\
        \ is returned only if the\ndata mention has been displayed to the requesting\
        \ user.\n\n**Note:** Quip has introduced faster, more scalable versions of\
        \ this\nAPI method:\n[Get Thread V2](#operation/getThreadV2),\n[Get Thread\
        \ HTML V2](#operation/getThreadHtmlV2),\n[Get Thread Members V2](#operation/getThreadMembersV2),\n\
        [Get Thread Invited Members V2](\n    #operation/getThreadInvitedMembersV2),\n\
        and\n[Get Thread Folders V2](#operation/getThreadFoldersV2).\nYou're encouraged\
        \ to modify your integrations to point to the\nlatest versions of API methods.\
        \ You can continue to access legacy\nversions of API methods until we announce\
        \ when support for them ends.\n\nSee Also:\n\n* [REST API Versioning FAQ](#section/FAQs/REST-API-Versioning-FAQ)\n"
      parameters:
      - name: id
        in: path
        schema:
          type: string
        required: true
        description: The ID or secret path of the thread to inspect.
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/thread_info_v1'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /2/threads/{threadIdOrSecretPath}:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Threads
      summary: Get Thread V2
      operationId: getThreadV2
      description: 'Returns basic information about a Quip thread (document,

        spreadsheet, or chat). This information includes things such as

        the ID, title, last time the thread was edited and the thread''s

        link sharing settings.

        '
      parameters:
      - $ref: '#/components/parameters/thread_id_or_secret_path_for_get'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/thread_get_v2'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /2/threads/{threadIdOrSecretPath}/html:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Threads
      summary: Get Thread Html V2
      operationId: getThreadHtmlV2
      description: 'Get the body of the thread in html format.


        If Mirrored Salesforce Permissions is enabled, data included in a

        document by using a Salesforce Data Mention is returned only if the

        data mention has been displayed to the requesting user.

        '
      parameters:
      - $ref: '#/components/parameters/thread_id_or_secret_path'
      - $ref: '#/components/parameters/cursor'
      - $ref: '#/components/parameters/limit'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/thread_get_html_v2_response'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
        '504':
          $ref: '#/components/responses/504_gateway_timeout'
  /2/threads/{threadIdOrSecretPath}/invited-members:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Threads
      summary: Get Thread Invited Members V2
      operationId: getThreadInvitedMembersV2
      description: 'Returns the list of users who were invited via email to become

        direct members of a Quip thread (document, spreadsheet, or chat).

        Use this API method to monitor requests for collaboration with people

        outside of your Quip site.




        Note: This API method doesn''t return the list of users who are already

        direct members of a thread.

        '
      parameters:
      - $ref: '#/components/parameters/thread_id_or_secret_path'
      - $ref: '#/components/parameters/cursor'
      - $ref: '#/components/parameters/limit'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/thread_get_invited_members_v2_response'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/threads/lock-edits:
    post:
      security:
      - OAuth2:
        - USER_MANAGE
      tags:
      - Threads
      summary: Lock or Unlock a Thread
      operationId: lockThread
      description: 'Lock or unlock edits to a thread.

        '
      requestBody:
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties:
                thread_id:
                  type: string
                  description: 'The ID or secret path of the thread whose document
                    you

                    want to modify.

                    '
                edits_disabled:
                  type: boolean
                  description: If true this will disable edits on this thread. If
                    false, it will enable edits on this thread.
              required:
              - thread_id
              - edits_disabled
      parameters:
      - name: Content-Type
        in: header
        schema:
          type: string
        example: application/x-www-form-urlencoded
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                description: Empty JSON object
                type: object
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/threads/lock-section-edits:
    post:
      security:
      - OAuth2:
        - USER_MANAGE
      tags:
      - Threads
      summary: Lock or Unlock a Section
      operationId: lockThreadSection
      description: 'Lock or unlock edits to a section.

        '
      requestBody:
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties:
                thread_id:
                  type: string
                  description: 'The ID or secret path of the thread you want to modify.

                    '
                section_id:
                  type: string
                  description: 'The ID for the section you want to lock or unlock.

                    '
                edits_disabled:
                  type: string
                  description: If true this will disable edits for this section. If
                    false, it will enable edits for this thread.
              required:
              - thread_id
              - section_id
              - edits_disabled
      parameters:
      - name: Content-Type
        in: header
        schema:
          type: string
        example: application/x-www-form-urlencoded
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/thread_info_v1'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/threads/live-paste:
    post:
      security:
      - OAuth2:
        - USER_READ
        - USER_WRITE
      tags:
      - Threads
      summary: Create a Live Paste Section In a Document
      operationId: createLivePasteSection
      description: 'Add a section to a document that tracks another section and can

        automatically update when the source section is updated.


        We determine where to insert the new content based on the `location`

        argument. Some `location` values are relative to another section,

        which is specified by `destination_section_id`, enabling fine-grained

        editing. For example, to add a section to the end of an existing

        section, you would send the ID of the existing section in the list as

        the `destination_section_id` and send `2: AFTER_SECTION` as the

        `location`.


        To get the IDs of sections in an existing document, parse the HTML

        returned by the [Get Thread](#operation/getThread).

        Every paragraph, list item, and table cell will have an HTML `id`

        attribute you can use in this method. Live Paste does not support

        individual items in lists.


        Alternatively the content of both the source and the destination

        document can be referred to by document ranges. A document range is a

        heading plus all sections underneath it up to the next heading of same

        or larger size. The `location` values `6`, `7` and `8` support

        document ranges in combination with `destination_document_range` for

        the destination document. The `is_document_range_source` parameter

        supports document ranges for the source document when set to `True`,

        in combination with the `source_document_range` parameter. Document

        ranges are available for documents only, i.e. not for spreadsheets.

        '
      requestBody:
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties:
                source_thread_id:
                  type: string
                  description: 'The ID or secret path of the thread to copy from.

                    '
                is_document_range_source:
                  type: boolean
                  default: false
                  description: 'If `true`, `source_document_range` is required and
                    is where the content of the source thread is acquired. If `source_section_ids`
                    is provided in this case, an error will be returned.


                    If `false`, the content is referenced by `source_section_ids`.
                    In this case, `source_section_ids` is required and an error is
                    returned if `source_document_range` is provided.

                    '
                source_section_ids:
                  type: string
                  description: A comma-separated list of sequential sections of the
                    source thread to copy. Required if `is_document_range_source`
                    is set to `false`.
                source_document_range:
                  type: string
                  description: 'The string of the heading in the source document that
                    defines the document range you want to copy. The document range
                    includes the header and all sections below it until the next heading
                    of the same size or larger. This parameter is required if `is_document_range_source`
                    is set to `true`.

                    '
                destination_thread_id:
                  type: string
                  description: The ID of the thread you want to modify.
                location:
                  type: string
                  default: 0
                  enum:
                  - 1
                  - 2
                  - 3
                  - 4
                  - 6
                  - 7
                  - 8
                  - 9
                  description: "Where we should insert the new content.\n- `0: APPEND`\
                    \ - Append to the end of the document.\n- `1: PREPEND` - Prepend\
                    \ to the beginning of the document.\n- `2: AFTER_SECTION` - Insert\
                    \ after the section specified\n  by `section_id`.\n\n- `3: BEFORE_SECTION`\
                    \ - Insert before the section\n  specified by `section_id`.\n\n\
                    - `4: REPLACE_SECTION` - Delete the section specified by\n  `section_id`\
                    \ and insert the new content at that\n  location.\n\n- `6: AFTER_DOCUMENT_RANGE`\
                    \ - Insert after the document\n  range specified by `document_range`.\n\
                    \n- `7: BEFORE_DOCUMENT_RANGE` - Insert before the document\n\
                    \  range specified by `document_range`.\n\n- `8: REPLACE_DOCUMENT_RANGE`\
                    \ - Delete the document range\n  specified by `document_range`\
                    \ and insert the new content\n  at that location.\n\n(`5` is intentionally\
                    \ omitted to have same numbering scheme as the edit-document endpoint.)\n\
                    Options `6`, `7` and `8` work only on documents.\n"
                destination_section_id:
                  type: string
                  description: The ID or secret path of the thread to be modified.
                    This cannot be the same as the `source_thread_id`. Required for
                    `location` values `6` - `8`.
                destination_document_range:
                  type: string
                  description: 'The string of the header in the destination document
                    that defines the document range you want to modify. Required for
                    `location` values `1` - `4`

                    '
                update_automatic:
                  type: string
                  description: If set to true, the destination section will update
                    automatically when the source section changes. Live Pastes will
                    not be able to update automatically if the admin has disabled
                    automatic updates for Live Paste in the Admin Console.
                  default: true
              required:
              - source_thread_id
              - destination_thread_id
      parameters:
      - name: Content-Type
        in: header
        schema:
          type: string
        example: application/x-www-form-urlencoded
      responses:
        '200':
          description: Example Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/thread_info_v1'
              examples:
                example1:
                  summary: Example Response
                  value:
                    thread:
                      author_id: HcLAEARatvR
                      thread_class: document
                      id: SIdAAANKtjW
                      created_usec: 1588263820524431
                      updated_usec: 1588264045370339
                      title: Test destination document
                      link: https://corp.quip.com/EJGEA1dknX2g
                      type: document
                      document_id: SIdABA4DG5G
                    user_ids:
                    - HcLAEARatvR
                    shared_folder_ids: []
                    expanded_user_ids:
                    - HcLAEARatvR
                    invited_user_emails: []
                    html: "<h1 id='SIdACAn15zN'>Test destination document</h1>\n<p\
                      \ id='SIdACAAhXse' class='line'>\u200B</p>\n<p id='SIdACAYNoUk'\
                      \ class='line'>\u200B</p>\n"
                example2:
                  summary: Live Paste with Document Ranges
                  value:
                    thread:
                      author_id: HcLAEARatvR
                      thread_class: document
                      id: SIdAAANKtjW
                      created_usec: 1588263820524431
                      updated_usec: 1603817042093259
                      title: Test destination document
                      link: https://corp.quip.com/EJGEA1dknX2g
                      type: document
                      is_template: false
                      owning_company_id: DYTAcAiIFUr
                      document_id: SIdABA4DG5G
                      is_deleted: false
                    user_ids:
                    - HcLAEARatvR
                    - bZBAEARddtM
                    shared_folder_ids: []
                    expanded_user_ids:
                    - bZBAEARddtM
                    - HcLAEARatvR
                    invited_user_emails: []
                    html: '<h1 id=''SIdACAn15zN''>Test destination document</h1>

                      <p id=''SIdACArENSx'' class=''line''>

                      This is a test section</p>

                      <h1>id=''SIdACAxnStn''>Another H1 Header</h1>

                      '
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/threads/mark-as-moved-to-external: {}
  /2/threads/{threadIdOrSecretPath}/members:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Threads
      summary: Get Thread Members V2
      operationId: getThreadMembersV2
      description: 'Returns the list of users who are members of a Quip thread (document,
        spreadsheet, or chat) because they were added to it directly. Use this API
        method to monitor information-sharing on your Quip site.



        Note: This API method doesn''t return the list of users who were added via
        other means including:

        - Folder-sharing

        - Link-sharing

        - Salesforce Synced Sharing

        - Email invitation.'
      parameters:
      - $ref: '#/components/parameters/thread_id_or_secret_path_for_get'
      - $ref: '#/components/parameters/cursor'
      - $ref: '#/components/parameters/limit'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/thread_get_members_v2_response'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /2/threads/:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Threads
      summary: Get Threads V2
      operationId: getThreadsV2
      description: 'Bulk variant of the

        [Get Thread](#operation/getThreadV2) endpoint.


        Returns basic information about multiple Quip threads

        (documents, spreadsheets, or chats). This information for each

        thread includes things such as the ID, title,

        last time the thread was edited and the thread''s

        link sharing settings.

        '
      parameters:
      - name: ids
        in: query
        schema:
          type: string
        required: true
        description: 'The IDs or secret paths of the threads to get information about.

          You can pass in a maximum of 100 of either of these

          identifiers:


          * `ID`: You can find this in the "id" response field of the

          [Get Thread](#operation/getThread) API method.


          * `secret path`: You can find this in the URL of a thread.

          For example, in this URL:

          "https://quip.com/3fs7B2leat8/TrackingDocument",

          the secret path is 3fs7B2leat8. You can also find this ID in

          the "secret_path" response field of this API method.

          '
      responses:
        '200':
          description: Successful response.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/thread_multi_get_v2'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '413':
          $ref: '#/components/responses/413_payload_too_large'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/threads/:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Threads
      deprecated: true
      summary: Get Threads
      operationId: getThreads
      description: 'Bulk variant of the

        [Get Thread](#operation/getThread) endpoint.


        Returns basic information about multiple Quip threads (documents,

        spreadsheets, or chats). This information for each thread includes

        things such as the ID, title, last time the thread was edited and

        the thread''s link sharing settings.


        **Note:** Quip has introduced a faster, more scalable version of this

        API method:

        [Get Threads V2](#operation/getThreadsV2).

        You''re encouraged to modify your integrations to point to the

        latest versions of API methods. You can continue to access legacy

        versions of API methods until we announce when support for them ends.


        See Also:


        * [REST API Versioning FAQ](#section/FAQs/REST-API-Versioning-FAQ)

        '
      parameters:
      - name: ids
        in: query
        schema:
          type: string
        required: true
        description: A list of thread IDs or secret paths.
        example: KSRAAAikr74,LSRAAAikr74
      responses:
        '200':
          description: A map from thread IDs to thread information.
          content:
            application/json:
              schema:
                type: object
                additionalProperties:
                  x-additionalPropertiesName: thread_id
                  allOf:
                  - $ref: '#/components/schemas/thread_info_v1'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '413':
          $ref: '#/components/responses/413_payload_too_large'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/threads/new-chat:
    post:
      security:
      - OAuth2:
        - USER_WRITE
      tags:
      - Threads
      summary: Create a Chat Room
      operationId: createChatRoom
      description: 'Creates a chat room.

        '
      requestBody:
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties:
                message:
                  type: string
                  description: Plain text content of the new message that is posted
                    by the author of the chat room. Content must not exceed 100KB.
                title:
                  type: string
                  description: 'The title of the new chat room. Title length must
                    not

                    exceed 10 KB.

                    '
                member_ids:
                  type: string
                  description: 'A comma-separated list of user IDs to add as members
                    to

                    the chat room.

                    '
              required:
              - title
      parameters:
      - name: Content-Type
        in: header
        schema:
          type: string
        example: application/x-www-form-urlencoded
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                allOf:
                - $ref: '#/components/schemas/thread_info_v1'
                - example:
                    thread:
                      type: chat
                      thread_class: channel
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/threads/new-document:
    post:
      security:
      - OAuth2:
        - USER_WRITE
      tags:
      - Threads
      summary: Create a Document or Spreadsheet
      operationId: createDocument
      description: 'Creates a document or spreadsheet, returning the new thread in
        the

        same format as [Get Thread](#operation/getThread).


        This endpoint doesn''t support slides anymore because they''re retired

        as described in [this article](

        https://help.salesforce.com/s/articleView?id=000355252&type=1).

        '
      requestBody:
        content:
          application/x-www-form-urlencoded:
            schema:
              $ref: '#/components/schemas/new_document_request'
      parameters:
      - name: Content-Type
        in: header
        schema:
          type: string
        example: application/x-www-form-urlencoded
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/thread_info_v1'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/threads/recent:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Threads
      summary: Get Recent Threads
      operationId: getRecentThreads
      description: 'Returns the most recent threads to have received messages, similar
        to

        the updates view in the Quip app. Results are returned in the same

        format as [Get Thread](#operation/getThread).

        '
      parameters:
      - name: count
        in: query
        schema:
          type: integer
          minimum: 1
          maximum: 50
          default: 10
        description: The number of threads to return.
      - name: max_updated_usec
        in: query
        schema:
          type: integer
          format: int64
        description: 'UNIX epoch timestamp. Searches only for threads that were last

          updates before or at this timestamp.

          '
      - name: include_hidden
        in: query
        schema:
          type: boolean
        description: If true, response includes hidden threads.
      responses:
        '200':
          description: A map from thread IDs to thread information.
          content:
            application/json:
              schema:
                type: object
                additionalProperties:
                  x-additionalPropertiesName: thread_id
                  allOf:
                  - $ref: '#/components/schemas/thread_info_v1'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/threads/remove-members:
    post:
      security:
      - OAuth2:
        - USER_MANAGE
      tags:
      - Threads
      summary: Remove People from a Thread or Remove a Thread from Folders
      operationId: removeMembersFromThreadOrThreadFromFolders
      description: 'Removes the given individuals from the given thread and/or removes
        the

        thread from the given folders. We return the updated thread in same

        format as [Get Thread](#operation/getThread).

        '
      requestBody:
        content:
          application/x-www-form-urlencoded:
            schema:
              $ref: '#/components/schemas/thread_remove_members_v1_request'
      parameters:
      - name: Content-Type
        in: header
        schema:
          type: string
        example: application/x-www-form-urlencoded
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/thread_info_v1'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/threads/resolve-data-mentions/{thread_id}: {}
  /1/threads/search:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Threads
      summary: Search for Threads
      operationId: searchForThreads
      description: 'Returns a list of threads whose content matches words in the given

        query. Threads are sorted from most to least relevant.

        '
      parameters:
      - name: query
        in: query
        schema:
          type: string
        required: true
        description: 'A text string containing words delimited by spaces used to match

          thread content or titles.

          '
        example: <query>
      - name: count
        in: query
        schema:
          type: integer
          default: 10
          maximum: 50
        description: The maximum number of results to return.
      - name: only_match_titles
        in: query
        schema:
          type: boolean
          default: false
        description: 'If set to true, the search will match words in document titles

          rather than content. Typically much faster if you only want to get

          documents with a certain title.

          '
      responses:
        '200':
          description: Example Response
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/thread_info_v1'
                example:
                - thread:
                    updated_usec: 1497546190102488
                    author_id: QGPAEAHhrEM
                    created_usec: 1497545872752906
                    id: NCSAAAVEZZE
                    link: https://quip.com/Tr4lAymRMVeX
                    thread_class: document
                    type: document
                    title: Expense Report Q2 FY18
                - thread:
                    updated_usec: 1498163965704797
                    author_id: QGPAEAHhrEM
                    created_usec: 1497545838650473
                    id: cRLAAA665U4
                    link: https://quip.com/BDZdAyQlcDnb
                    thread_class: document
                    type: document
                    title: Dreamforce expense report
                - thread:
                    updated_usec: 1498507612435964
                    author_id: QGPAEAHhrEM
                    created_usec: 1497545924280456
                    sharing:
                      company_mode: VIEW
                      company_id: LbdAcAwVVIA
                    id: LFUAAAJTGNZ
                    link: https://quip.com/3J84AoiBA7gY
                    thread_class: document
                    type: document
                    title: Expense reports for 2018 off-sites
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '429':
          $ref: '#/components/responses/429_too_many_requests'
        '500':
          $ref: '#/components/responses/500_server_error'
        '503':
          $ref: '#/components/responses/503_rate_limit'
  /2/threads/{threadIdOrSecretPath}/table-column-names: {}
  /2/threads/{threadIdOrSecretPath}/tables: {}
  /1/blob/{thread_id}/{blob_id}:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Threads
      summary: Get a Blob from a Thread
      operationId: getBlobFromThread
      description: 'Gets an image or other blob from the Quip document or

        spreadsheet associated with your specified `thread_id`.

        To find the `blob_id`, inspect the Quip document or

        spreadsheet in a browser and search for the `blob_id`

        in the "sources".


        ### Response


        In the case of success, the response is raw binary, so this endpoint

        can be used to display images.


        In the case of failure, the response will return an object with an

        `error` field.

        '
      parameters:
      - name: If-None-Match
        in: header
        required: false
        schema:
          type: string
        description: 'Header containing a `blob_id`. If this ID matches the path

          parameter `blob_id` and the blob exists, an HTTP status code 304

          is returned.

          '
      - name: thread_id
        in: path
        schema:
          type: string
        description: 'The ID or secret path of the thread the blob belongs to.

          '
        required: true
      - name: blob_id
        in: path
        schema:
          type: string
        description: The ID of the blob to retrieve.
        required: true
      responses:
        '200':
          description: Successful Response
          content:
            '*/*':
              schema:
                description: 'Binary data. Content type is the content type of the

                  stored blob.

                  '
                type: string
                format: binary
        '304':
          $ref: '#/components/responses/304_not_modified'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/blob/{thread_id}:
    post:
      security:
      - OAuth2:
        - USER_WRITE
      tags:
      - Threads
      summary: Add a Blob to a Thread
      operationId: addBlobToThread
      description: 'Uploads an image or other blob to the given thread. Returns a
        `url`

        that may be used in the `content` field of

        [Edit Document](#operation/editDocument)

        requests and an `id` that may be used in the `attachment` field of

        [Add a Message](#operation/addMessage).

        '
      requestBody:
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties:
                blob:
                  type: string
                  description: 'The image or blob binary.

                    '
                  format: binary
              required:
              - blob
      parameters:
      - name: thread_id
        in: path
        description: 'The ID or secret path of the thread the blob will be added to.

          '
        schema:
          type: string
        required: true
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    description: Unique ID of the added blob.
                    type: string
                  url:
                    description: 'The relative URL to reference the blob in document

                      edits.

                      '
                    type: string
                required:
                - id
                - url
                example:
                  id: DiPp1ZQyC8QUtvBT4vojzM
                  url: /blob/LeSAAAqaCfc/DiPp1ZQyC8QUtvBT4vojzM
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/messages/{thread_id}:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Messages
      summary: Get Recent Messages
      operationId: getRecentMessages
      description: 'Returns a list of the most recent messages for the given thread.

        '
      parameters:
      - name: thread_id
        in: path
        schema:
          type: string
        description: The ID of the thread to return recent messages for.
        required: true
      - name: count
        in: query
        schema:
          type: integer
          default: 25
          minimum: 1
          maximum: 100
        description: Number of messages to return.
      - name: max_created_usec
        in: query
        schema:
          type: integer
          format: int64
        description: A UNIX timestamp in microseconds. If given, we return messages
          created at and before the given timestamp. The messages will be sorted by
          creation time in descending order if `sort_by` or `sorted_by` are not provided.
          If either `updated_since_usec` or `last_updated_since_usec` is provided,
          this parameter is ignored.
      - name: updated_since_usec
        in: query
        schema:
          type: integer
          format: int64
        description: 'A UNIX timestamp in microseconds. If given, we return messages

          last updated at and after the given timestamp. The messages will

          be sorted by last update time in ascending order if `sort_by` or

          `sorted_by` are not provided.

          '
      - name: last_updated_since_usec
        in: query
        schema:
          type: integer
          format: int64
        description: 'A UNIX timestamp in microseconds. If given, we return messages

          last updated before the given timestamp. The messages will

          be sorted by last update time in ascending order if `sort_by` or

          `sorted_by` are not provided.

          '
      - name: sorted_by
        in: query
        schema:
          type: string
          enum:
          - ASC
          - DESC
        description: 'Determines whether to sort messages in ascending or descending

          order.

          '
      - name: sort_by
        in: query
        schema:
          type: string
          enum:
          - ASC
          - DESC
        description: Alias for `sorted_by`.
      - name: message_type
        in: query
        schema:
          type: string
          enum:
          - message
          - edit
          default: message
        description: Determines the type of messages to return. If `edit`, document
          edit messages will be returned. Otherwise, regular messages will be returned.
      responses:
        '200':
          description: Example Response
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/message_record'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/messages/new:
    post:
      security:
      - OAuth2:
        - USER_WRITE
      tags:
      - Messages
      summary: Add a Message
      operationId: addMessage
      description: Adds a required chat message, which can either be plain text content
        or contain attachments, to the given thread, posted as the authenticated user.
      requestBody:
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties:
                thread_id:
                  type: string
                  description: 'The ID of the thread the message will be added to.

                    '
                  example: FCKAAAPEi7C
                frame:
                  type: string
                  enum:
                  - bubble
                  - card
                  - line
                  description: 'Adjusts the display type of the message.

                    '
                content:
                  type: string
                  description: Plain text content of the new message (ignored if `parts`
                    is supplied). There is a maximum size of 100kb per message.
                  example: Hello there!
                silent:
                  type: boolean
                  default: false
                  description: 'If set to True, we do not send any push notifications
                    or emails for the message. If set to False, we use the default
                    notifications for users on the thread.

                    '
                parts:
                  $ref: '#/components/schemas/message_parts_input'
                attachments:
                  type: string
                  description: 'A comma-separated list of blob IDs previously uploaded
                    to this thread with [Add a Blob](#operation/addBlobToThread).

                    '
                annotation_id:
                  type: string
                  description: 'The ID of a document comment. If provided, the message

                    will be placed in the comment. Only one of `annotation_id`

                    and `section_id` are allowed.

                    '
                section_id:
                  type: string
                  description: 'If present, the message will be added as a comment
                    on the document section with this ID. Only one of `section_id`
                    and `annotation_id` are allowed.

                    '
                name:
                  type: string
                  description: 'The name of the apparent user if the authorized user
                    of

                    this request is a bot. This is for messages created from

                    a Quip integration.

                    '
                user_id:
                  type: string
                  description: 'The Quip user ID of the apparent user if the authorized

                    user of this request is a bot. This is for messages

                    created from a integration.

                    '
                profile_picture:
                  type: string
                  description: 'The URL for the profile picture of the apparent user
                    if

                    the authorized user of this request is a bot. This is for

                    messages created from a Quip integration.

                    '
                email:
                  type: string
                  description: 'The email of the apparent user if the authorized user
                    of

                    this request is a bot. This is for messages created from a

                    Quip integration.

                    '
                service_id:
                  type: string
                  description: 'An external service ID for the message if the authorized

                    user of this request is a bot. This is for messages

                    created from a Quip integration and is used to prevent

                    integrations from duplicating messages.

                    '
                url:
                  type: string
                  description: 'An external URL linked from the message if the authorized

                    user of this request is a bot. This is for messages

                    created from a Quip integration.

                    '
              required:
              - thread_id
      parameters:
      - name: Content-Type
        in: header
        schema:
          type: string
        example: application/x-www-form-urlencoded
      responses:
        '200':
          description: Example Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/message_record'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '410':
          description: Gone
          content:
            application/json:
              schema:
                allOf:
                - $ref: '#/components/schemas/base_error_response'
                - properties:
                    error_code:
                      default: 510
                      description: 'The authorized bot user no longer has access to

                        the thread.

                        '
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/folders/add-members:
    post:
      security:
      - OAuth2:
        - USER_MANAGE
      tags:
      - Folders
      summary: Add People to a Folder
      operationId: addMembersToFolder
      description: 'Shares the given folder with the given user IDs.

        '
      requestBody:
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties:
                folder_id:
                  type: string
                  description: The ID of the folder to update.
                member_ids:
                  type: string
                  description: A comma-separated list of user IDs.
              required:
              - folder_id
              - member_ids
      parameters:
      - name: Content-Type
        in: header
        schema:
          type: string
        example: application/x-www-form-urlencoded
      - $ref: '#/components/parameters/folder_include_chats'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/folder_info'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/folders/{id}:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Folders
      summary: Get Folder
      operationId: getFolder
      description: 'Returns the given folder.

        To find your desktop or archive folder ID, see [Get Authenticated

        User](#operation/getUser).

        '
      parameters:
      - name: id
        in: path
        schema:
          type: string
        description: ID of the folder whose information you want to get.
        required: true
      - $ref: '#/components/parameters/folder_include_chats'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/folder_info'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /2/folders/{folderIdOrSecretPath}/link-sharing-settings:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Folders
      summary: Get Folder Link Sharing Settings
      operationId: getFolderLinkSharingSettings
      description: 'Identifies the link sharing settings for your specified folder.


        ### See also


        [Link Share Folders

        ](https://help.salesforce.com/s/articleView?id=000389898&type=1)


        ### Sample Call


        In this example, we''re getting the link sharing settings for a folder

        with ID **XaABCAlgycE**.


        ```text

        GET https://platform.quip.com/2/folders/XaABCAlgycE/link-sharing-settings

        Authorization: Bearer ABCSampleAccessToken

        ```

        '
      parameters:
      - $ref: '#/components/parameters/folder_id_or_secret_path'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/folder_get_link_sharing_response'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
    put:
      security:
      - OAuth2:
        - USER_MANAGE
      tags:
      - Folders
      summary: Edit Folder Link Sharing Settings
      operationId: setFolderLinkSharingSettings
      description: "Modifies a Quip folder's link sharing settings. When you enable\
        \ link\nsharing on a folder, everyone at your company can view, edit, and\n\
        share the contents of that folder. You can also use this API method\nto enable\
        \ or disable read-only access for people outside of your\ncompany.\n\nFor\
        \ example, if you have a folder that contains data to be shared with\nyour\
        \ whole company, you can enable link sharing on the folder. That\nway, all\
        \ employees can use the shareable link to automatically get\naccess to any\
        \ new or updated content in that folder. If you enable\nexternal access, people\
        \ your employees collaborate with outside of\nyour company also automatically\
        \ get access to that content.\n\n### See also\n\n[Link Share Folders\n](https://help.salesforce.com/s/articleView?id=000389898&type=1)\n\
        \n### Sample Call\nIn this example, we're enabling link sharing on a folder\
        \ with ID\n**XaABCAlgycE**.\n\n```text\nPUT https://platform.quip.com/2/folders/XaABCAlgycE/link-sharing-settings\n\
        Content-Type: application/json\nAuthorization: Bearer ABCSampleAccessToken\n\
        \n{\n    \"link_sharing_enabled\": \"True\",\n    \"external_access_allowed\"\
        : \"False\"\n}\n```\n"
      parameters:
      - $ref: '#/components/parameters/folder_id_or_secret_path'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/folder_put_link_sharing_request'
      responses:
        '204':
          description: Successful Response
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/folders/:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Folders
      summary: Get Folders
      operationId: getFolders
      description: 'Bulk variant of the

        [Get Folder](#operation/getFolder) endpoint.

        Returns an object mapping IDs to folder objects.

        '
      parameters:
      - name: ids
        in: query
        schema:
          type: string
        required: true
        description: A comma-separated list of folder IDs.
        example: BULAOADdLWL,CULAOADdLWL
      - $ref: '#/components/parameters/folder_include_chats'
      responses:
        '200':
          description: Map from folder IDs to folder objects
          content:
            application/json:
              schema:
                type: object
                additionalProperties:
                  x-additionalPropertiesName: folder_id
                  allOf:
                  - $ref: '#/components/schemas/folder_info'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/folders/new:
    post:
      security:
      - OAuth2:
        - USER_MANAGE
      tags:
      - Folders
      summary: Create a Folder
      operationId: createFolder
      description: 'Creates a folder.

        '
      parameters:
      - $ref: '#/components/parameters/folder_include_chats'
      requestBody:
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties:
                title:
                  type: string
                  description: The name of the folder.
                color:
                  type: string
                  description: The color of the folder.
                  enum:
                  - manila
                  - red
                  - orange
                  - green
                  - blue
                  - purple
                  - dark_yellow
                  - light_red
                  - light_orange
                  - light_green
                  - light_blue
                  - light_purple
                  default: manila
                member_ids:
                  type: string
                  description: 'A comma-separated list of user IDs to add as members
                    of

                    this folder.

                    '
                parent_id:
                  type: string
                  description: If given, we make the folder a child of the given folder.
                    If not given, we create the folder in the authenticated user's
                    Private folder.
              required:
              - title
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/folder_info'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/folders/remove-members:
    post:
      security:
      - OAuth2:
        - USER_MANAGE
      tags:
      - Folders
      summary: Remove People from a Folder
      operationId: removeMembersFromFolder
      description: 'Removes the given User IDs from the given folder.

        '
      parameters:
      - $ref: '#/components/parameters/folder_include_chats'
      requestBody:
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties:
                folder_id:
                  type: string
                  description: The ID of the folder to modify.
                member_ids:
                  type: string
                  description: A comma-separated list of user IDs.
                  example: UTUAEAiZl6B,TTUAEAiZl6B
              required:
              - folder_id
              - member_ids
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/folder_info'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/folders/update:
    post:
      security:
      - OAuth2:
        - USER_MANAGE
      tags:
      - Folders
      summary: Update a Folder
      operationId: updateFolder
      description: 'Updates a folder.

        '
      parameters:
      - $ref: '#/components/parameters/folder_include_chats'
      requestBody:
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties:
                folder_id:
                  type: string
                  description: The ID of the folder to update.
                title:
                  type: string
                  description: The new title of the folder.
                  example: Changed name from API
                color:
                  type: string
                  description: The new color of the folder.
                  enum:
                  - manila
                  - red
                  - orange
                  - green
                  - blue
                  - purple
                  - dark_yellow
                  - light_red
                  - light_orange
                  - light_green
                  - light_blue
                  - light_purple
              required:
              - folder_id
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/folder_info'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/users/contacts:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Users
      summary: Get Contacts
      operationId: getContacts
      description: 'Returns a list of contacts for the authenticated user.

        '
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/user_contacts'
                - type: object
                  description: Empty JSON object.
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/users/current:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Users
      summary: Get Current User
      operationId: getCurrentUser
      description: 'Returns information about the authenticated user.

        '
      parameters:
      - name: sort_by
        in: query
        schema:
          type: string
          enum:
          - title
          - created_usec
          - updated_usec
        description: 'Determines which field to sort the `shared_folder_ids`

          and `group_folder_ids` lists by.

          '
      - name: sort_order
        in: query
        schema:
          type: string
          enum:
          - asc
          - desc
          default: asc
        description: 'Determines what order to sort the `shared_folder_ids`

          and `group_folder_ids` lists by. `asc` sorts the lists in

          ascending order while `desc` sorts the lists in descending order.

          '
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                allOf:
                - $ref: '#/components/schemas/user_info'
                - required:
                  - desktop_folder_id
                  - archive_folder_id
                  - starred_folder_id
                  - private_folder_id
                  - trash_folder_id
                  - shared_folder_ids
                  - group_folder_ids
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/users/current/threads:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Users
      summary: Get Current User's Threads
      operationId: getCurrentUserThreads
      description: 'Returns information about Quip threads owned by the current user.

        Threads include: documents and spreadsheets, chats (2-person and

        group), Slack channel conversations linked to Quip (also called

        "channels"), and slides. You can use the returned information for

        eDiscovery and eArchiving purposes. For example, you can pass the

        returned thread IDs into another API call to export the threads to

        [.docx](#operation/editShareLinkSettings) or

        [PDF](#operation/createExportThreadToPdfRequest) files. Then you can

        save the exported files in your archiving system.

        Note: this endpoint doesn''t return threads to which the current user

        obtains access through open folder by workgroup (ofbwg).


        ### Sample Calls

        In this first example, we''re getting a list of the first 50 threads

        owned by the current user. Since the user owns more that 50 threads,

        we''ll get a `next_cursor` value in the response and pass that value

        into the next call in step 2.


        ```text

        GET https://platform.quip.com/1/users/current/threads?limit=50

        Authorization: Bearer {{ABCSampleAccessToken}}

        ```


        In this example, we''re getting a list of the next 50 threads owned

        by a user with ID ABCEAmpgev at a company with ID **DEFAcAV4DT7**.

        We''re passing in the `next_cursor` value returned by the previous

        call from step 1.


        ```text

        GET https://platform.quip.com/1/users/current/threads?limit=50&cursor=bmV4dCBjdXJzb3I

        Authorization: Bearer {{ABCSampleAccessToken}}

        ```

        '
      parameters:
      - name: threads_meta
        in: query
        schema:
          type: boolean
          default: false
        description: 'Determines whether to include basic thread data in the response.

          Allowable values for this field are:


          * `true`: Return `thread_id`, `updated_usec`, `link`, and

          `is_deleted` on each thread.


          * `false`: Return `thread_id` on each thread.

          '
      - name: include_deleted
        in: query
        schema:
          type: boolean
          default: false
        description: 'Determines whether to return threads that the current user has

          been removed from. Allowable values for this field are:


          * `true`: Return threads that the user has been removed from.


          * `false`: Don''t return threads that the user has been removed

          from.

          '
      - name: thread_ids
        in: query
        schema:
          type: string
        description: 'Comma-separated list of thread IDs owned by the current user.

          You can pass in either of these identifiers:


          * `ID`: You can find this in the "id" response field of the

          [Get a Thread](#operation/getThread) API method.


          * `secret path`: You can find this in the URL of a thread.

          For example, in this URL:

          "https://quip.com/3fs7B2leat8/TrackingDocument", the secret

          path is 3fs7B2leat8.

          '
        example: UcZ9AAhvqrc,AVN9AAeqq5w
      - name: limit
        in: query
        schema:
          type: integer
          default: 100
          maximum: 100
          minimum: 1
        description: 'The maximum number of threads to return.

          '
      - name: cursor
        in: query
        schema:
          type: string
        description: 'A pointer to the next page of thread data to return. Use a cursor

          to incrementally get the next set of thread data. When you call

          this API method for the first time, leave the cursor field blank.

          For all calls after that first one, pass in the `next_cursor`

          value returned by your previous Get User''s Threads call.

          Continue to call Get User''s Threads with each new cursor value

          until the `next_cursor` field returns empty.


          **Note**: Each `next_cursor` value returned by this API method

          expires 30 minutes after creation. After a cursor expires, you

          can call Get User''s Threads again to get a new cursor.

          '
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/user_threads'
                - $ref: '#/components/schemas/user_threads_meta'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/users/current/threads-modified-after-usec: {}
  /1/users/{id}:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Users
      summary: Get User
      operationId: getUser
      description: 'Returns the user with the specified ID.

        '
      parameters:
      - name: id
        in: path
        schema:
          type: string
        description: 'The ID or email address of the user to get information for.
          Note:

          Email-based lookups return information about a user from only the

          same company as the caller. That''s the company of the person who

          created the API key associated with your provided access token.

          '
        required: true
      - name: sort_by
        in: query
        schema:
          type: string
          enum:
          - title
          - created_usec
          - updated_usec
        description: 'Determines which field to sort the `shared_folder_ids`

          and `group_folder_ids` lists by, if they''re included in the

          response.

          '
      - name: sort_order
        in: query
        schema:
          type: string
          enum:
          - asc
          - desc
          default: asc
        description: 'Determines what order to sort the `shared_folder_ids`

          and `group_folder_ids` lists by, if they''re included in the

          response. `asc` sorts the lists in ascending order while `desc`

          sorts the lists in descending order.

          '
      responses:
        '200':
          description: Example Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/user_info'
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/limited_session: {}
  /1/users/:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Users
      summary: Get Users
      operationId: getUsers
      description: 'Bulk variant of the [Get User](#operation/getUser) endpoint. Returns

        an object with the passed in user IDs or emails as properties and

        user objects as values. If a user ID or email is not found, then its

        value will be an error message instead.

        '
      parameters:
      - name: ids
        in: query
        schema:
          type: string
        required: true
        description: 'A comma-separated list of either emails or user IDs. Must not

          exceed 1000 emails or user IDs. Note: Email-based lookups return

          information about a user from only the same company as the caller.

          That''s the company of the person who created the API key

          associated with your provided access token.

          '
      - name: sort_by
        in: query
        schema:
          type: string
          enum:
          - title
          - created_usec
          - updated_usec
          default: asc
        description: 'Determines which field to sort the `shared_folder_ids`

          and `group_folder_ids` lists by, if they''re included in the

          response.

          '
      - name: sort_order
        in: query
        schema:
          type: string
          enum:
          - asc
          - desc
        description: 'Determines what order to sort the `shared_folder_ids`

          and `group_folder_ids` lists by, if they''re included in the

          response. `asc` sorts the lists in ascending order while `desc`

          sorts the lists in descending order.

          '
      responses:
        '200':
          description: Map from user ID or email to email object
          content:
            application/json:
              schema:
                type: object
                additionalProperties:
                  x-additionalPropertiesName: user_id_or_email
                  allOf:
                  - $ref: '#/components/schemas/user_info'
                  - $ref: '#/components/schemas/user_not_found_err_property'
                example:
                  UTUAEAiZl6B:
                    name: John Doe
                    emails:
                    - john.doe@example.com
                    id: UTUAEAiZl6B
                    created_usec: 1631916773945747
                    is_robot: false
                    affinity: 0.0
                    disabled: false
                  jane.doe@example.com:
                    name: Jane Doe
                    id: TTUAEAiZl6B
                    is_robot: false
                    affinity: 0.36
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '413':
          $ref: '#/components/responses/413_payload_too_large'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/users/read-only:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Users
      summary: Get Users Read Only
      operationId: getUsersReadOnly
      description: Gets the read-only status of users.
      parameters:
      - name: user_ids
        in: query
        schema:
          type: array
          items:
            type: string
          maxItems: 1000
          minItems: 1
          description: 'A comma separated list of user IDs.

            '
          example: SSSAEAOPHIA,QUEAEAENBEY
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  read_only:
                    type: array
                    items:
                      type: string
                    description: A list of read-only user IDs.
                  non_read_only:
                    type: array
                    items:
                      type: string
                    description: A list of non-read-only user IDs.
                  not_found:
                    type: array
                    items:
                      type: string
                    description: A list of user IDs which are not found.
                required:
                - read_only
                - non_read_only
                - not_found
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '429':
          $ref: '#/components/responses/429_too_many_requests'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/users/subdomain: {}
  /1/users/update:
    post:
      security:
      - OAuth2:
        - USER_MANAGE
      tags:
      - Users
      summary: Update User
      operationId: updateUser
      description: 'Updates the provided user. If the authenticated user is a bot
        user,

        users of the same company can be updated. Otherwise, only the

        authenticated user can be updated. Currently only supports updating

        the user''s profile picture.

        '
      requestBody:
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties:
                user_id:
                  type: string
                  description: 'The ID or email address of the user to update. If
                    not

                    provided, the authorized user''s ID is used by default.

                    '
                picture:
                  type: string
                  format: binary
                  description: 'The picture to use as the user''s profile picture.
                    One of

                    `picture` or `picture_url` must be provided.

                    '
                picture_url:
                  type: string
                  description: 'The URL to the picture to use as the user''s profile

                    picture. One of `picture` or `picture_url` must be

                    provided.

                    '
                sort_by:
                  type: string
                  enum:
                  - title
                  - created_usec
                  - updated_usec
                  default: asc
                  description: 'Determines which field to sort the `shared_folder_ids`

                    and `group_folder_ids` lists by.

                    '
                sort_order:
                  type: string
                  enum:
                  - asc
                  - desc
                  description: 'Determines what order to sort the `shared_folder_ids`

                    and `group_folder_ids` lists by. `asc` sorts the lists in

                    ascending order while `desc` sorts the lists in descending

                    order.

                    '
      parameters:
      - name: Content-Type
        in: header
        schema:
          type: string
        example: application/x-www-form-urlencoded
      responses:
        '200':
          description: Example Response
          content:
            application/json:
              schema:
                allOf:
                - $ref: '#/components/schemas/user_info'
                - required:
                  - desktop_folder_id
                  - archive_folder_id
                  - starred_folder_id
                  - private_folder_id
                  - trash_folder_id
                  - shared_folder_ids
                  - group_folder_ids
        '400':
          $ref: '#/components/responses/400_bad_request'
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '404':
          $ref: '#/components/responses/404_not_found'
        '500':
          $ref: '#/components/responses/500_server_error'
  /1/websockets/new:
    get:
      security:
      - OAuth2:
        - USER_READ
      tags:
      - Realtime
      summary: New Websocket
      operationId: newWebsocket
      description: "Returns a websocket URL to connect to. The URL may expire if no\n\
        connection is initiated within 60 seconds.\n\n### Websocket Events:\nEach\
        \ event sent through the websocket is a JSON object with a type\nindicating\
        \ what happened.\n\n**`type`** - What type of event this packet represents.\
        \ The list of\ntypes include the following:\n\n- `message` - A new message\
        \ was sent, includes message, user, and\nthread.\n- `heartbeat` - Periodically\
        \ sent to keep the connection open.\n- `alive` - Reply sent if the client\
        \ sends {\"type\": \"heartbeat\"}.\n- `error` - Sent in response to any unrecognized\
        \ command, includes\ndebug.\n\n**`message`** - A Quip message in the format\
        \ described in\n[Get Recent Messages](#operation/getRecentMessages).\n\n**`user`**\
        \ - An object containing the ID and name of the user who sent\nthe message.\n\
        \n**`thread`** - An object containing the ID and title (if any) of the\nthread\
        \ the message was sent on.\n\n**`debug`** - A string with additional debug\
        \ information.\n\n### Example Websocket Events:\n\n```text\n{\n    \"type\"\
        : \"heartbeat\"\n}\n\n{\n    \"type\": \"alive\"\n}\n\n{\n    \"type\": \"\
        error\",\n    \"debug\": \"Unsupported command.\"\n}\n```\n"
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  url:
                    type: string
                    description: The websocket URL to connect to.
                  user_id:
                    type: string
                    description: The ID of the user that made the request.
                required:
                - url
                - user_id
                example:
                  url: wss://listen0.quip.com:443/platform/listen/0?t=1
                  user_id: KaDAEAinU0V
        '401':
          $ref: '#/components/responses/401_authentication'
        '403':
          $ref: '#/components/responses/403_forbidden'
        '500':
          $ref: '#/components/responses/500_server_error'
