openapi: 3.0.3
info:
  version: v2
  title: Firstup API
  termsOfService: https://firstup.io/legal/terms-of-service/
  contact:
    name: Support
    url: https://support.firstup.io/hc/en-us
  description: >
    <div style="background-color: #f3e8ff; padding: 15px; border-left: 5px solid
    #7c3aed; margin-bottom: 20px;">
      <strong> Beta Notice:</strong> This portal is currently in beta. Some functionality, like <b>Try it</b> is temporarily disabled.
    </div>

    <br></br>

    <b>API Concepts and Overview</b>

    <p>Each API concept can be found in our Docs; we give an overview of each
    API, the expected behavior and what is possible. </p>


    <p>Technical details are found in this reference, but some complex
    technicalities are further explained in our docs. </p> 


    <p>Further technical guidance on SCIM patching, pagination and filtering can
    be found in our docs:</p>
          <ul>
        <li><a href="/usermanagementapi/scim-patch-operations">SCIM patching</a></li>
        <li><a href="/gettingstarted/pagination">Pagination</a></li>
        <li><a href="/gettingstarted/filtering">Filtering</a></li>
        <li><a href="/guides">Use case examples</a></li>
      </ul>
    <b>Technical Details</b>

    <br></br>

    <p>
     From this page you can download the <a href="/api-docs">OpenAPI specification for the Firstup API</a>. This can be imported into tools such
     as Postman to generate a collection of test queries or converted into an SDK using <a href="https://swagger.io/tools/swagger-codegen/">Swagger Codegen</a>. Alternatively, you can use the try me function in this platform. 
    </p>

    <b>Authorization</b>

    <br></br>

    <p class="code-below">
      All API endpoints use the JSON content type and require an auth token. See <a href="/authorization">Authentication and Authorization</a> for more details on token management.
      The token and content type should be explicitly set in the request headers. For example:
    </p>


    <pre class="code">
      curl -X GET "https://partner.socialchorus.com/v2/channels" -H "accept: application/json" -H "Authorization: Bearer &lt;ACCESS TOKEN&gt;"
    </pre>


    <div class='sc-swag'>
      <b>Main API Sections</b>
      <br></br>
      <ul>
        <li><a href="/doorman/openapi/content-publishing">Content Publishing</a></li>
        <li><a href="/doorman/openapi/feeds">Feeds</a></li>
        <li><a href="/doorman/openapi/user-management">User Management (SCIM)</a></li>
        <li><a href="/doorman/openapi/user-groups">User Group Management (SCIM)</a></li>
        <li><a href="/doorman/openapi/webhooks">Webhooks</a></li>
        <li><a href="/doorman/openapi/assistant-inbox">Assistant Inbox</a></li>
        <li><a href="/doorman/openapi/user-roles">User Roles</a></li>
        <li><a href="/doorman/openapi/notification-center">Notification Center</a></li>
      </ul>
      <hr>
    </div>
externalDocs:
  description: Firstup Developer Portal
  url: /
tags:
  - name: Content Publishing
    description: >
      <p>The Content Publishing API provides access to content the same way
      Program Studio does, enabling the creation and updating of
      <b>articles</b>, <b>links</b>, <b>videos</b>, and <b>images</b>.</p>

      <p></p>
        <ul>
          <li>
            <b>Security:</b> Users with a &ldquo;publisher&rdquo; or higher role can work with
            content in this admin-like function. A 403 code is returned for content-related requests
            to users without a &ldquo;publisher&rdquo; or higher role. Permissions are not granular;
            any authenticated user may read, update, or take action on any existing content. See <a href="/usermanagementapi/user-role-provisioning">user roles and access</a> for more guidance. 
          </li>
        </ul>
        <p></p>
        <ul>
          <li>
            <b>States:</b> Content is initially created in the &ldquo;draft&rdquo; state. It becomes
            fully visible in feeds when it has passed the &ldquo;review&rdquo; state (meaning that
            it requires review) and is in the &ldquo;published&rdquo; state. Content can also pass
            through &ldquo;archived&rdquo; (similar to deleted), &ldquo;scheduled&rdquo; (content to
            be published in the future automatically), &ldquo;processing&rdquo; (refers to media
            that is still being processed or uploaded; like content in the &ldquo;draft&rdquo;
            state, this content does not become &ldquo;published&rdquo; until processing has
            completed), and &ldquo;processing error&rdquo; (media or similar objects that fail
            during the processing phase; this content cannot be transitioned to another state)
            states.
          </li>
        </ul>
        <p></p>
        <ul>
          <li>
            <b>Sources:</b> Content sources include &ldquo;submitted&rdquo; (by users);
            &ldquo;Pinterest,&rdquo; &ldquo;RSS,&rdquo; &ldquo;Facebook,&rdquo;
            &ldquo;Twitter,&rdquo; and &ldquo;Instagram&rdquo; (for content harvested from external
            sources); &ldquo;SocialChorus CPCM&rdquo; (for content that is republished between
            programs); &ldquo;studio&rdquo; (for admin-created content); and &ldquo;OAuth
            Client&rdquo; (for content published via the Partner API or other OAuth client).</li>
        </ul>
        <p>For contextual guidance on content publishing, and for use case examples, refer to our <a href="/contentandpublishing/contentoverview">Content Publishing Overview page</a>.</p>
  - name: Feeds
    description: >
      <p>The Feeds API provides access to lists of content similar to how a user
      sees them in the Firstup experience application. Feeds are specific to the
      authenticated user and a user can only see what the platform gives them
      access to. </p>

      <p>At their core, feeds are built using filters to find the exact topics
      and type of posts your application wishes to expose to its users. One of
      the basic filters is the <code>channels.id</code> filter, but there are
      additional filters like <code>content_type</code> and
      <code>visibility</code>. There are also preset configurations called
      <em>named feeds</em>, which uses the <code>name</code> query parameter and
      are convenient wrappers around a set of filters. These include things like
      "trending" posts, "following", and "myfeed". The full list of feed names
      is outlined in the <a
      href="/doorman/openapi/feeds/listfeedposts">listFeedPosts</a>
      documentation. </p>

      <p>Feeds are paginated, but have no total records as they are an
      inherently dynamic list of posts.</p> <p>Actions like liking, bookmarking,
      and responding to polls can be taken on individual posts in the same way
      they can be taken on the experience applications.</p>

      <p>For contexctual guidance on feeds, and for use examples, refer to our
      <a href="/feeds/feedsoverview">feeds overview page</a>.</p> 
  - name: User Management
    description: >
      The User Management API adheres to the [SCIM 2.0](https://scim.cloud/)
      protocol unless otherwise stated, and provides management and provisioning
      of users in a program. <br><br> Managing users requires that the acting
      user have a role of Program Manager or Administrator, and users can only
      create or update users with a role less than or equal to their own. 

      <p>For further guidance on User Management, refer to:</p>
              <ul>
          <li>
            <a href="/usermanagementapi/user-management-overview">User Management contextual overview</a>.
          </li>
        </ul>
        <p></p>
        <ul>
          <li>
            <a href="/usermanagementapi/user-provisioning">User provisioning use case examples</a>.
          </li>
        </ul>
        <p></p>
        <ul>
          <li>
            <a href="/usermanagementapi/scim-patch-operations">SCIM patching and user editing use case examples</a>.</li>
        </ul>
                <p></p>
        <ul>
          <li>
            <a href="/usermanagementapi/custom-attributes">Custom user attributes overview</a>.</li>
        </ul>
                        <p></p>
        <ul>
          <li>
            <a href="/usermanagementapi/user-role-provisioning">User role and access</a>.</li>
        </ul>
  - name: User Groups
    description: >
      The Group Management API adheres to the

      [SCIM 2.0](https://scim.cloud/) protocol ***unless otherwise

      stated***, and provides management and provisioning of Groups and its

      members (Users) within a Program.


      Managing Groups requires that the acting User have a role of Program
      Manager

      or Administrator, and Group read and/or write access.


      <b>Note: User groups are SCIM groups only. Currently this API does not
      support creating audiences.</b> 
  - name: Webhooks
    description: >
      <p>The Webhooks API provides a mechanism for subscribing to events that
      occur within the Firstup platform to receive http payloads when those
      events occur. Use webhook subscriptions to trigger actions on your own
      application.</p> <p></p> <p>Webhook events are sent by the Firstup
      platform as POST requests to your webhook url. Each event contains a
      payload specific to that event. More information about the webhooks
      system, including a list of events that can be subscribed to, is available
      on the <a href="/webhooks/webhooks-overview"> Webhooks page</a>.</p>
  - name: Assistant Inbox
    description: >
      <b>Note: This API is getting deprecated and is replaced by the <a
      href="/doorman/openapi/notification-center">Notification Center</a>.</b>
paths:
  /v2/feed/posts:
    get:
      operationId: listFeedPosts
      tags:
        - Feeds
      summary: Return a user's feed of posts
      description: >
        Provides a list of posts in the user’s feed. Accepts pagination and
        filtering parameters.
      parameters:
        - name: name
          in: query
          description: >
            Use a specific named feed, which is a preset of filters for specific
            types of feeds. By default, requests return the "myfeed" feed, which
            includes posts the user can see but may not necessarily be
            following. Specifying a name not listed here will result in a 400
            Bad Request error.
          required: false
          schema:
            type: string
            enum:
              - myfeed
              - following
              - resources
              - trending
              - icymi
              - featured
              - bookmarked
              - community_images
            default: myfeed
        - name: search
          in: query
          description: >
            Find content matching provided keywords. When specified, parameters
            other than pagination and the topics filter will be ignored.
          required: false
          schema:
            type: string
        - name: filter.user_behaviors
          in: query
          description: >-
            Return content posts that users have interacted with in the provided
            ways. Defaults to all content if left empty.
          required: false
          schema:
            type: array
            items:
              type: string
              enum:
                - liked
                - bookmarked
                - read
                - unread
        - name: filter.channels.id
          in: query
          description: >-
            Build the feed from the given topics. Provide a list as either array
            or comma separated list. Returns posts that are published to ANY of
            the topics. Defaults to all topics.
          required: false
          style: form
          explode: false
          schema:
            type: array
            items:
              type: integer
        - name: filter.initiative_tags.id
          in: query
          description: >-
            Build the feed from the given initiative tags. Provide a list as
            either array or comma separated list. Returns posts that are
            published with ANY of the initiative tags. Defaults to all content.
          required: false
          style: form
          explode: false
          schema:
            type: array
            items:
              type: integer
        - name: filter.content_type
          in: query
          description: >-
            Return only content matching the provided types, which can be a
            single type or a list as either array or comma separated list.
            Possible values include 'article', 'link', 'note', 'image', and
            'video'. Defaults to all types. Including a type not listed here
            will result in a 400 Bad Request error.
          required: false
          style: form
          explode: false
          schema:
            type: array
            items:
              type: string
              enum:
                - article
                - link
                - note
                - image
                - video
        - name: filter.visibility
          in: query
          description: Limit records to the value provided.
          schema:
            type: string
            enum:
              - public
              - private
              - any
            default: any
        - name: filter.featured
          in: query
          description: Limit records to the value provided.
          schema:
            type: string
            enum:
              - true
              - false
              - any
            default: any
        - $ref: '#/components/parameters/page.size'
        - $ref: '#/components/parameters/page.number'
      requestBody:
        $ref: '#/components/requestBodies/listFeedPostsIds'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Feeds.Post.Resource'
                  meta:
                    properties:
                      filters:
                        description: A list of the filters applied in the current request.
                        example:
                          content_type: article
                          visibility: public
                      feed_name:
                        description: The name of the current feed, if named.
                        example: myfeed
                      pagination:
                        $ref: '#/components/schemas/Standard.Feed.Meta.PagePagination'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - feeds.read
      x-swagger-router-controller: feed
  /v2/feed/posts/{content_id}:
    get:
      operationId: detailFeedPost
      tags:
        - Feeds
      summary: Return the details of a single post within a feed
      description: >-
        Provides the data for a single post in a user’s feed. The post must be
        visible to the user or a 404 Not Found response will be returned.
      parameters:
        - name: content_id
          in: path
          description: ID of the detailed post
          required: true
          schema:
            type: integer
        - name: locale
          in: query
          description: locale (for translatable posts)
          required: false
          schema:
            type: string
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    $ref: '#/components/schemas/Feeds.Post.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - feeds.read
      x-swagger-router-controller: feed
  /v2/feed/posts/{content_id}/engagement:
    get:
      operationId: detailFeedPostEngagement
      tags:
        - Feeds
      summary: Return the engagement details of a single post within a feed
      description: >
        Displays the user’s engagements related to a single feed post, including
        a timestamp for each type of engagement; for example, a liked_at
        timestamp is present if the user has liked the post and a bookmarked_at
        is present if the user has bookmarked the post. The post must be visible
        to the user or a 404 Not Found response will be returned.
      parameters:
        - name: content_id
          in: path
          description: ID of the post
          required: true
          schema:
            type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    $ref: '#/components/schemas/Feeds.PostEngagement.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - feeds.read
      x-swagger-router-controller: feed
  /v2/feed/posts/{content_id}/like:
    put:
      operationId: likePost
      tags:
        - Feeds
      summary: Like a post in the feed
      description: >
        Creates a "like" engagement of a specific feed post for a scoped user.
        The post must be visible to the user or a 404 Not Found response will be
        returned; for example, this would happen if the content is published to
        a targeted topic that does not target the user.
      parameters:
        - name: content_id
          in: path
          description: ID of the post. The post must be visible to the user.
          required: true
          schema:
            type: integer
      responses:
        '204':
          description: Feed Post Liked
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - feeds.engage
      x-swagger-router-controller: feed
  /v2/feed/posts/{content_id}/unlike:
    put:
      operationId: unlikePost
      tags:
        - Feeds
      summary: Unlike a post in the feed
      description: >
        Unlikes a feed post for a scoped user. Unliking effectively removes an
        existing “like” engagement. The post must be visible to the user or a
        404 Not Found response will be returned; for example, this would happen
        if the content is published to a targeted topic that does not target the
        user.
      parameters:
        - name: content_id
          in: path
          description: ID of the post. The post must be visible to the user.
          required: true
          schema:
            type: integer
      responses:
        '204':
          description: Feed Post Unliked
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - feeds.engage
      x-swagger-router-controller: feed
  /v2/feed/posts/{content_id}/bookmark:
    put:
      operationId: bookmarkPost
      tags:
        - Feeds
      summary: Bookmark a post in the feed
      description: >
        Creates a “bookmark” engagement of a specific feed post for a scoped
        user. The post must be visible to the user or a 404 Not Found response
        will be returned; for example, this would happen if the content is
        published to a targeted topic that does not target the user.
      parameters:
        - name: content_id
          in: path
          description: ID of the post. The post must be visible to the user.
          required: true
          schema:
            type: integer
      responses:
        '204':
          description: Feed Post Bookmarked
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - feeds.engage
      x-swagger-router-controller: feed
  /v2/feed/posts/{content_id}/unbookmark:
    put:
      operationId: unbookmarkPost
      tags:
        - Feeds
      summary: Unbookmark a post in the feed
      description: >-
        Unbookmarks a feed post for a scoped user. Unbookmarking effectively
        removes an existing “bookmark” engagement. The post must be visible to
        the user or a 404 Not Found response will be returned; for example, if
        the content is published to a targeted topic that does not target the
        user.
      parameters:
        - name: content_id
          in: path
          description: ID of the post. The post must be visible to the user.
          required: true
          schema:
            type: integer
      responses:
        '204':
          description: Feed Post Unbookmarked
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - feeds.engage
      x-swagger-router-controller: feed
  /v2/feed/posts/{content_id}/share/trackable_url:
    get:
      operationId: generateTrackableUrl
      tags:
        - Feeds
      summary: Get the trackable URL for a post in the feed
      description: >
        Get the trackable URL for a feed post for a scoped user. The post must
        be visible to the user or a 400 bas request will be returned.
      parameters:
        - name: content_id
          in: path
          description: ID of the post. The post must be visible to the user.
          required: true
          schema:
            type: integer
      responses:
        '200':
          description: Feed Post trackable URL
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: object
                    properties:
                      trackable_url:
                        type: string
                        description: The shortened trackable URL for the post
                        example: https://bit.ly/abcdefg
                      uniquified_original_url:
                        type: string
                        description: The non-shortened trackable URL for the post
                        example: >-
                          https://onfirstup.com/acme/acmetimes/articles/myarticle?bypass_deeplink=true
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      x-swagger-router-controller: feed
  /v2/feed/posts/{content_id}/share:
    put:
      operationId: sharePost
      tags:
        - Feeds
      summary: Share a post in the feed
      description: >-
        Indicates that the post has been shared by a scoped user. The post must
        be visible to the user or a 400 bas request will be returned.
        ``share_url`` can be retrieved using GET
        ``/v2/feed/posts/{content_id}/share/trackable_url``.
      parameters:
        - name: content_id
          in: path
          description: ID of the post. The post must be visible to the user.
          required: true
          schema:
            type: integer
      requestBody:
        content:
          application/json:
            schema:
              type: object
              required:
                - platform
                - content_channel_id
                - share_url
              properties:
                platform:
                  description: >-
                    The platform the post was shared to. Supported platforms are
                    ``facebook``, ``twitter``, ``linked_in`` and ``copy``.
                    ``copy`` is used for when the post was copied to the
                    clipboard. Platforms not listed here will be accepted and
                    treated as ``other``.
                  example: facebook
                  type: string
                content_channel_id:
                  description: The ID of the content channel where the post is viewed.
                  example: 42
                  type: integer
                share_url:
                  description: >-
                    The URL that has been shared.It  can be retrieved using GET
                    ``/v2/feed/posts/{content_id}/share/trackable_url``
                  example: https://bit.ly/abcdefg
                  type: string
      responses:
        '204':
          description: Feed Post share intent is recorded
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - feeds.engage
      x-swagger-router-controller: feed
  /v2/feed/posts/{content_id}/view:
    put:
      operationId: viewPost
      tags:
        - Feeds
      summary: View a post in the feed
      description: >
        Marks a specific feed post as viewed for a scoped user. Viewing is
        considered as the user having interacted with the content enough to
        qualify as at least partial consumption. The post must be visible to the
        user or a 404 Not Found response will be returned.
      parameters:
        - name: content_id
          in: path
          description: ID of the post. The post must be visible to the user.
          required: true
          schema:
            type: integer
      responses:
        '204':
          description: Feed Post Viewed
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - feeds.engage
      x-swagger-router-controller: feed
  /v2/feed/posts/{content_id}/unview:
    put:
      operationId: unviewPost
      tags:
        - Feeds
      summary: Unview a post in the feed
      description: >
        Reverses a view operation on a feed post for a scoped user. Unviewing is
        used in cases where a view was mistakenly recorded. The post must be
        visible to the user or a 404 Not Found response will be returned.
      parameters:
        - name: content_id
          in: path
          description: ID of the post. The post must be visible to the user.
          required: true
          schema:
            type: integer
      responses:
        '204':
          description: Feed Post Unviewed
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - feeds.engage
      x-swagger-router-controller: feed
  /v2/feed/posts/{content_id}/comments:
    get:
      operationId: listFeedPostComments
      tags:
        - Feeds
      summary: List the comments on a content post
      description: >-
        List the comments on a content post. Only top-level comments are
        returned. Comments which are replies to other comments are not currently
        available through this endpoint.
      parameters:
        - name: content_id
          in: path
          description: ID or UUID of the content post
          required: true
          schema:
            type: integer
        - $ref: '#/components/parameters/page.size'
        - $ref: '#/components/parameters/page.number'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Feed.Comment.Resource'
                  meta:
                    properties:
                      filters:
                        description: A list of the filters applied in the current request.
                      pagination:
                        $ref: '#/components/schemas/Standard.Meta.PagePagination'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          $ref: '#/components/responses/Common.Response.UnauthenticatedError'
        '403':
          $ref: '#/components/responses/Common.Response.UnauthorizedError'
      security:
        - oauth2_as_a_user:
            - feeds.read
      x-swagger-router-controller: feed
    post:
      operationId: createFeedPostComment
      tags:
        - Feeds
      summary: Comment on a post in the feed
      parameters:
        - name: content_id
          in: path
          description: ID or UUID of the content post
          required: true
          schema:
            type: integer
      requestBody:
        content:
          application/json:
            schema:
              type: object
              required:
                - body
              properties:
                body:
                  description: Comment body
                  example: This is a comment or reply to a comment.
                  type: string
        description: Comment data
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Feed.Comment.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          $ref: '#/components/responses/Common.Response.UnauthenticatedError'
        '403':
          $ref: '#/components/responses/Common.Response.UnauthorizedError'
      security:
        - oauth2_as_a_user:
            - feeds.engage
      x-swagger-router-controller: feed
  /v2/feed/posts/{content_id}/comments/{comment_id}/replies:
    get:
      operationId: listFeedPostCommentReplies
      tags:
        - Feeds
      summary: List the replies to a comment on a content post
      description: List the replies to a comment on a content post.
      parameters:
        - name: content_id
          in: path
          description: ID or UUID of the content post
          required: true
          schema:
            type: integer
        - name: comment_id
          in: path
          description: ID or UUID of the comment
          required: true
          schema:
            oneOf:
              - type: integer
              - type: string
                format: uuid
        - $ref: '#/components/parameters/page.size'
        - $ref: '#/components/parameters/page.number'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Feed.Comment.Resource'
                  meta:
                    properties:
                      filters:
                        description: A list of the filters applied in the current request.
                      pagination:
                        $ref: '#/components/schemas/Standard.Meta.PagePagination'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          $ref: '#/components/responses/Common.Response.UnauthenticatedError'
        '403':
          $ref: '#/components/responses/Common.Response.UnauthorizedError'
      security:
        - oauth2_as_a_user:
            - feeds.read
      x-swagger-router-controller: feed
  /v2/feed/posts/{content_id}/comments/{comment_id}/{post_number}/replies:
    post:
      operationId: createFeedPostCommentReply
      tags:
        - Feeds
      summary: Reply to a comment on a post in the feed
      parameters:
        - name: content_id
          in: path
          description: ID or UUID of the content post
          required: true
          schema:
            type: integer
        - name: comment_id
          in: path
          description: ID or UUID of the comment to reply to
          required: true
          schema:
            oneOf:
              - type: integer
              - type: string
                format: uuid
        - name: post_number
          in: path
          description: post_number of the comment to reply to
          required: true
          schema:
            type: integer
      requestBody:
        content:
          application/json:
            schema:
              type: object
              required:
                - body
              properties:
                body:
                  description: Comment body
                  example: This a reply to a comment.
                  type: string
        description: Comment data
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Feed.Comment.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          $ref: '#/components/responses/Common.Response.UnauthenticatedError'
        '403':
          $ref: '#/components/responses/Common.Response.UnauthorizedError'
      security:
        - oauth2_as_a_user:
            - feeds.engage
      x-swagger-router-controller: feed
  /v2/feed/posts/{content_id}/comments/{comment_id}:
    put:
      operationId: updateFeedPostComment
      tags:
        - Feeds
      summary: Update a comment on a post in the feed
      description: >-
        Update an existing comment record. The body attribute can be provided
        and only those provided will be updated. <br><br> Response body data
        will be the updated record.
      parameters:
        - name: content_id
          in: path
          description: ID or UUID of the content post.
          required: true
          schema:
            type: integer
        - name: comment_id
          in: path
          description: ID or UUID of the comment post
          required: true
          schema:
            oneOf:
              - type: integer
              - type: string
                format: uuid
      requestBody:
        content:
          application/json:
            schema:
              type: object
              required:
                - body
              properties:
                body:
                  description: Comment body
                  example: This is an updated comment.
                  type: string
        description: Comment data
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Feed.Comment.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          $ref: '#/components/responses/Common.Response.UnauthenticatedError'
        '403':
          $ref: '#/components/responses/Common.Response.UnauthorizedError'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - feeds.engage
      x-swagger-router-controller: feed
  /v2/feed/posts/{content_id}/rendered:
    get:
      operationId: renderFeedPost
      tags:
        - Feeds
      summary: Return the rendered content of a single post within the feed
      description: >-
        Provides the rendered content for a single post in a user’s feed. The
        post must be visible to the user or a 404 Not Found response will be
        returned.
      parameters:
        - name: content_id
          in: path
          description: ID of the post
          required: true
          schema:
            type: integer
        - name: locale
          in: query
          description: Locale (for translatable posts)
          required: false
          schema:
            type: string
        - name: target_platform
          in: query
          description: The target platform the post should be rendered for.
          required: false
          schema:
            type: string
            enum:
              - android
              - email
              - ios
              - microapp
              - public_content
              - web
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    $ref: '#/components/schemas/Feeds.RenderedPost.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - feeds.rendered.read
      x-swagger-router-controller: feed
  /v2/feed/posts/{content_id}/acknowledge:
    post:
      operationId: acknowledgeFeedPost
      tags:
        - Feeds
      summary: Acknowledge a post in the feed.
      description: >-
        Acknowledges a feed post for a scoped user. The post must be visible to
        the user or a 404 Not Found response will be returned; for example, if
        the content is published to a targeted channel that does not target the
        user.
      parameters:
        - name: content_id
          in: path
          description: ID of the post. The post must be visible to the user.
          required: true
          schema:
            type: integer
      responses:
        '204':
          description: Feed Post Acknowledged
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - feeds.engage
      x-swagger-router-controller: feed
  /v2/feed/polls/{poll_id}:
    get:
      operationId: showFeedPoll
      tags:
        - Feeds
      summary: Returns the details of a single poll.
      description: Provides data for a single poll.
      parameters:
        - name: poll_id
          in: path
          description: ID of the poll
          required: true
          schema:
            type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    $ref: '#/components/schemas/Feeds.Poll.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - feeds.rendered.read
      x-swagger-router-controller: feed
    post:
      operationId: respondFeedPoll
      tags:
        - Feeds
      summary: Respond to a poll.
      description: Respond to a poll.
      parameters:
        - name: poll_id
          in: path
          description: ID of the poll
          required: true
          schema:
            type: integer
      requestBody:
        content:
          application/json:
            schema:
              type: array
              items:
                type: string
        description: Answer data
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    $ref: '#/components/schemas/Feeds.Poll.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - feeds.engage
      x-swagger-router-controller: feed
  /v2/feed/polls:
    get:
      operationId: listFeedPolls
      tags:
        - Feeds
      summary: Returns a user's feed of polls.
      description: Provides a list of polls in the user's feed.
      requestBody:
        $ref: '#/components/requestBodies/listFeedPostsIds'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Feeds.Poll.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - feeds.rendered.read
      x-swagger-router-controller: feed
  /v2/feed/video/{video_id}:
    get:
      operationId: showFeedVideo
      tags:
        - Feeds
      summary: Experimental and undocumented video access
      description: Experimental internal API
      parameters:
        - name: video_id
          in: path
          description: Experimental Parameter
          required: true
          schema:
            type: string
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    $ref: '#/components/schemas/Feeds.Video.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - feeds.rendered.read
      x-swagger-router-controller: feed
  /v2/feed/attachments/{uuid}/status:
    get:
      operationId: getAttachmentStatus
      tags:
        - Feeds
      summary: Experimental and undocumented attachment access
      description: Experimental internal API
      parameters:
        - name: uuid
          in: path
          description: Experimental Parameter
          required: true
          schema:
            type: string
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    $ref: '#/components/schemas/Feeds.Attachment.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - feeds.rendered.read
      x-swagger-router-controller: feed
  /v2/channels:
    post:
      operationId: createChannel
      tags:
        - Content Publishing
      summary: Create a topic in the program
      description: Creates new topic in the program
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Content.Channel.Post.Resource'
        description: Attributes of the topic to create.
      responses:
        '201':
          description: Created
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    $ref: '#/components/schemas/Content.Channel.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - content.write
        - oauth2_as_a_server:
            - content.write
      x-swagger-router-controller: publishing
    get:
      operationId: listChannels
      tags:
        - Content Publishing
      summary: List all topics in the program
      description: >-
        Returns a list of topics and allows for sorting, filtering, and
        pagination of the records.<br> Response body is an array of records.
      parameters:
        - name: filter.state
          in: query
          description: Limit returned records to those that match the state(s) provided.
          required: false
          style: form
          explode: false
          schema:
            type: array
            items:
              type: string
              default: any
              enum:
                - archived
                - hidden
                - published
                - any
        - $ref: '#/components/parameters/page.size'
        - $ref: '#/components/parameters/page.number'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Content.Channel.Resource'
                  meta:
                    properties:
                      filters:
                        description: A list of the filters applied in the current request.
                        example:
                          state: published
                      pagination:
                        $ref: '#/components/schemas/Standard.Meta.PagePagination'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - content.read
        - oauth2_as_a_server:
            - content.read
      x-swagger-router-controller: publishing
  /v2/channels/{channel_id}:
    put:
      operationId: updateChannel
      tags:
        - Content Publishing
      summary: Update a topic in the program
      description: Updates a topic in the program
      parameters:
        - name: channel_id
          in: path
          description: ID of the topic. The topic must exist in the program.
          required: true
          schema:
            type: integer
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Content.Channel.Resource'
        description: Attributes of the topic to update.
      responses:
        '200':
          description: Updated
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    $ref: '#/components/schemas/Content.Channel.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - content.write
        - oauth2_as_a_server:
            - content.write
      x-swagger-router-controller: publishing
  /v2/channels/{channel_id}/followers:
    get:
      operationId: listChannelFollowers
      tags:
        - Content Publishing
      summary: List all followers of a topic
      description: >-
        Returns a list of all users who follow the topic, and allows for
        pagination of the records.<br> Response body is an array of records.
      parameters:
        - name: channel_id
          in: path
          description: ID of the topic. The topic must exist in the program.
          required: true
          schema:
            type: integer
        - $ref: '#/components/parameters/page.size'
        - $ref: '#/components/parameters/page.number'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Content.ChannelFollower.Resource'
                  meta:
                    properties:
                      pagination:
                        $ref: '#/components/schemas/Standard.Meta.PagePagination'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - content.read
        - oauth2_as_a_server:
            - content.read
      x-swagger-router-controller: publishing
  /v2/content:
    get:
      operationId: listContent
      tags:
        - Content Publishing
      summary: Fetch a collection of content
      description: >-
        Returns a list of content records and allows for sorting, filtering, and
        pagination of the records.<br> Response body is an array of records.
      parameters:
        - name: filter.content_type
          in: query
          description: >-
            Limit returned records to those that match the content_type(s)
            provided.
          required: false
          style: form
          explode: false
          schema:
            type: array
            items:
              type: string
              default: any
              enum:
                - article
                - link
                - video
                - image
                - note
                - any
        - name: filter.state
          in: query
          description: Limit returned records to those that match the state(s) provided.
          required: false
          style: form
          explode: false
          schema:
            type: array
            items:
              type: string
              default: any
              enum:
                - draft
                - published
                - review
                - archived
                - scheduled
                - processing
                - processing_error
                - any
        - name: filter.targeted_channels
          in: query
          description: Return content posts that are assigned to targeted topics
          required: false
          schema:
            type: string
            enum:
              - true
              - false
              - any
            default: any
        - name: filter.channels.id
          in: query
          description: Return content posts that are assigned to the topic.
          required: false
          style: form
          explode: false
          schema:
            type: array
            items:
              type: integer
        - name: filter.initiative_tags.id
          in: query
          description: >-
            Return content posts that are tagged with the provided initiative
            tags. Defaults to all content.
          required: false
          style: form
          explode: false
          schema:
            type: array
            items:
              type: integer
        - name: filter.visibility
          in: query
          description: Limit records to the value provided.
          required: false
          schema:
            type: string
            enum:
              - public
              - private
              - any
            default: any
        - name: filter.featured
          in: query
          description: Limit records to the value provided.
          required: false
          schema:
            type: string
            enum:
              - true
              - false
              - any
            default: any
        - name: filter.source.type
          in: query
          description: >-
            Limit returned records to records using the provided source.type
            value.
          required: false
          schema:
            type: string
            enum:
              - submitted
              - pinterest
              - rss
              - facebook
              - twitter
              - instagram
              - socialchorus_cpcm
              - studio
              - oauth_client
              - any
            default: any
        - name: filter.source.post_id
          in: query
          description: >-
            Limit results to records with the given unique identifier on the
            source system.
          required: false
          schema:
            type: string
        - name: filter.created_at.from
          in: query
          description: >
            Limit results to records created at or after this time, equivalent
            to a range filter of "{value} <= created_at <= now". Use in
            combination with ``created_at.to`` to specify a limited upper bound
            on the value range.

            Must be formatted as an ISO8601 timestamp or datestamp. Datestamps
            are assumed to be in UTC.
          schema:
            type: string
            format: date-time
        - name: filter.created_at.to
          in: query
          description: >
            Limit results to records created at or before this time, equivalent
            to a range filter of "forever <= created_at <= {value}". Use in
            combination with ``created_at.from`` to specify a limited lower
            bound on the value range.

            Must be formatted as an ISO8601 timestamp or datestamp. Datestamps
            are assumed to be in UTC.
          schema:
            type: string
            format: date-time
        - name: filter.updated_at.from
          in: query
          description: >
            Limit results to records created at or after this time, equivalent
            to a range filter of "{value} <= updated_at <= now". Use in
            combination with ``updated_at.to`` to specify a limited upper bound
            on the value range.

            Must be formatted as an ISO8601 timestamp or datestamp. Datestamps
            are assumed to be in UTC.
          schema:
            type: string
            format: date-time
        - name: filter.updated_at.to
          in: query
          description: >
            Limit results to records created at or before this time, equivalent
            to a range filter of "forever <= updated_at <= {value}". Use in
            combination with ``updated_at.from`` to specify a limited lower
            bound on the value range.

            Must be formatted as an ISO8601 timestamp or datestamp. Datestamps
            are assumed to be in UTC.
          schema:
            type: string
            format: date-time
        - name: filter.published_at.from
          in: query
          description: >
            Limit results to records created at or after this time, equivalent
            to a range filter of "{value} <= published_at <= now". Use in
            combination with ``published_at.to`` to specify a limited upper
            bound on the value range.

            Must be formatted as an ISO8601 timestamp or datestamp. Datestamps
            are assumed to be in UTC.
          schema:
            type: string
            format: date-time
        - name: filter.published_at.to
          in: query
          description: >
            Limit results to records created at or before this time, equivalent
            to a range filter of "forever <= published_at <= {value}". Use in
            combination with ``published_at.from`` to specify a limited lower
            bound on the value range.

            Must be formatted as an ISO8601 timestamp or datestamp. Datestamps
            are assumed to be in UTC.
          schema:
            type: string
            format: date-time
        - $ref: '#/components/parameters/page.size'
        - $ref: '#/components/parameters/page.number'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Content.Post.Resource'
                  meta:
                    properties:
                      filters:
                        description: A list of the filters applied in the current request.
                        example:
                          content_type: article
                          featured: true
                      pagination:
                        $ref: '#/components/schemas/Standard.Meta.PagePagination'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - content.read
        - oauth2_as_a_server:
            - content.read
      x-swagger-router-controller: publishing
    post:
      operationId: createContent
      tags:
        - Content Publishing
      summary: Create a new content post
      description: >
        Create a new content item and select what topics will include the
        content. The new content will be created in the “draft” state. <br><br>
        This endpoint only creates the post. If applicable, an image may be
        added later via the appropriate endpoint. If author.user_id is provided,
        it will be used to determine display_name and avatar_url, overriding any
        values provided for display_name and avatar_url. <br><br> Response body
        data will be the newly created record.
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                content_type:
                  default: article
                  description: The type of content to create
                  type: string
                  enum:
                    - article
                    - link
                    - video
                    - image
                  example: article
                title:
                  description: A title for the post
                  example: Example Post Title
                body:
                  description: The body text for the post. HTML is permitted.
                  example: Example post body
                summary:
                  description: Post summary blurb
                  example: Example post summary
                author:
                  $ref: '#/components/schemas/Content.Post.Resource.author'
                featured:
                  type: boolean
                  description: Whether the post is featured.
                  example: true
                featured_label:
                  type: string
                  description: The featured label.
                  example: A Label
                visibility:
                  type: string
                  default: private
                  description: >
                    An indication of the native availability of the post within
                    the Firstup platform. If 'public', the post has a
                    public_link_url and shares of the post should use that url
                    as the canonical url. If 'private', the post requires user
                    authentication to view.
                  enum:
                    - private
                    - public
                  example: private
                channels:
                  type: array
                  description: |
                    A list of topics the content will be published to.
                  items:
                    type: object
                    required:
                      - id
                    properties:
                      id:
                        type: integer
                        example: 789
                      hidden:
                        type: boolean
                        example: false
                        default: false
                source:
                  type: object
                  properties:
                    post_id:
                      type: string
                      description: >-
                        The unique identifier of the post on the source system,
                        if it is republished from another platform or
                        application.
                    posted_at:
                      type: string
                      description: >-
                        The timestamp at which the post was published on the
                        source system, if it is republished from another
                        platform or application.
                images:
                  $ref: '#/components/schemas/Content.Creation.Images'
                template:
                  properties:
                    id:
                      type: integer
                link_url:
                  description: The url if the content_type is link
        description: Attributes of the content to create.
      responses:
        '201':
          description: Content Created
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Content.Post.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          $ref: '#/components/responses/Common.Response.UnauthenticatedError'
        '403':
          $ref: '#/components/responses/Common.Response.UnauthorizedError'
        '422':
          description: Validation Failed
      security:
        - oauth2_as_a_user:
            - content.write
        - oauth2_as_a_server:
            - content.write
      x-swagger-router-controller: publishing
  /v2/content/{content_id}:
    get:
      operationId: detailContent
      tags:
        - Content Publishing
      summary: Fetch the details of a content post
      description: >-
        Read an existing content record. Returns a single record by identifier
        or by the content UUID.
      parameters:
        - name: content_id
          in: path
          description: ID of the detailed content post
          required: true
          schema:
            type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    $ref: '#/components/schemas/Content.Post.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - content.read
        - oauth2_as_a_server:
            - content.read
      x-swagger-router-controller: publishing
    put:
      operationId: updateContent
      tags:
        - Content Publishing
      summary: Update an existing content post
      description: >
        Update an existing content record. Content can be updated in any state,
        but some states have different validations. Any or all of the content
        attributes can be provided and only those provided will be updated.
        <br><br> This endpoint cannot be used to change content type, state, or
        topics. If author.user_id is provided, it will be used to determine
        display_name and avatar_url, overriding any values provided for
        display_name and avatar_url. <br><br> Response body data will be the
        updated record.
      parameters:
        - name: content_id
          in: path
          description: ID or UUID of the content post
          required: true
          schema:
            type: integer
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                title:
                  description: A title for the post
                  example: Example Post Title
                body:
                  description: The body text for the post. HTML is permitted.
                  example: Example post body
                summary:
                  description: Post summary blurb
                  example: Example post summary
                author:
                  $ref: '#/components/schemas/Content.Post.Resource.author'
                featured:
                  type: boolean
                  description: Whether the post is featured.
                  example: true
                featured_label:
                  type: string
                  description: The featured label.
                  example: A Label
                visibility:
                  type: string
                  default: private
                  enum:
                    - private
                    - public
                  description: >
                    An indication of the native availability of the post within
                    the Firstup platform. If 'public', the post has a
                    public_link_url and shares of the post should use that url
                    as the canonical url. If 'private', the post requires user
                    authentication to view.
                source:
                  type: object
                  properties:
                    post_id:
                      type: string
                      description: >
                        The unique identifier of the post on the source system,
                        if it is republished from another platform or
                        application.
                      example: abc123
                    posted_at:
                      type: string
                      description: >
                        The timestamp at which the post was published on the
                        source system, if it is republished from another
                        platform or application.
                      example: '2000-01-01T00:00:00Z'
                template:
                  properties:
                    id:
                      type: integer
                      example: 234
                images:
                  $ref: '#/components/schemas/Content.Creation.Images'
                link_url:
                  description: The url if the content_type is link
                  example: https://google.com
        description: Attributes of the content to update.
      responses:
        '200':
          description: Content Updated
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Content.Post.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          $ref: '#/components/responses/Common.Response.UnauthenticatedError'
        '403':
          $ref: '#/components/responses/Common.Response.UnauthorizedError'
        '422':
          description: Validation Failed
      security:
        - oauth2_as_a_user:
            - content.write
        - oauth2_as_a_server:
            - content.write
      x-swagger-router-controller: publishing
  /v2/content/{content_id}/archive:
    put:
      operationId: archiveContent
      tags:
        - Content Publishing
      summary: Archive an existing content post
      description: >
        Archive an existing content post. Transition the content state from any
        state directly to "archived". <br><br> Response body contains the latest
        version of the content record.
      parameters:
        - name: content_id
          in: path
          description: ID or UUID of the content post
          required: true
          schema:
            type: integer
      responses:
        '200':
          description: Content Archived
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    $ref: '#/components/schemas/Content.Post.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          $ref: '#/components/responses/Common.Response.UnauthenticatedError'
        '403':
          $ref: '#/components/responses/Common.Response.UnauthorizedError'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - content.write
        - oauth2_as_a_server:
            - content.write
      x-swagger-router-controller: publishing
  /v2/content/{content_id}/draft:
    put:
      operationId: draftContent
      tags:
        - Content Publishing
      summary: Draft an existing content post
      description: >
        Transition the content state of an existing content post to draft. A
        post can be set to draft from any any current state. If the post was
        published or archived, it will no longer be. <br><br> Response body is
        the updated record. Returns ``400 Bad Request`` if the content cannot be
        transitioned to 'draft' due to validation reasons.
      parameters:
        - name: content_id
          in: path
          description: ID or UUID of the content post
          required: true
          schema:
            type: integer
      responses:
        '200':
          description: Content Drafted
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    $ref: '#/components/schemas/Content.Post.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          $ref: '#/components/responses/Common.Response.UnauthenticatedError'
        '403':
          $ref: '#/components/responses/Common.Response.UnauthorizedError'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - content.write
        - oauth2_as_a_server:
            - content.write
      x-swagger-router-controller: publishing
  /v2/content/{content_id}/publish:
    put:
      operationId: publishContent
      tags:
        - Content Publishing
      summary: Publish an existing content post
      description: >
        Change the state of the content to “published.” If the content is
        already in the “published” state, this request does nothing. Content in
        a “scheduled” state remains scheduled. For all other states, the content
        is published immediately. <br> Publishing content requires that at least
        one topic be associated to the content, as content must always have at
        least one topic. <br><br> Response body is the updated record. This
        endpoint returns ``400 Bad Request`` if the content cannot be published.
        Some attributes have validations that are only applied when moving
        content to the published state. For example, content cannot be published
        until its title has been filled in.
      parameters:
        - name: content_id
          in: path
          description: ID or UUID of the content post
          required: true
          schema:
            type: integer
      responses:
        '200':
          description: Content Published
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    $ref: '#/components/schemas/Content.Post.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          $ref: '#/components/responses/Common.Response.UnauthenticatedError'
        '403':
          $ref: '#/components/responses/Common.Response.UnauthorizedError'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - content.write
        - oauth2_as_a_server:
            - content.write
      x-swagger-router-controller: publishing
  /v2/content/{content_id}/review:
    put:
      operationId: reviewContent
      tags:
        - Content Publishing
      summary: Mark an existing post as ready for review
      description: >
        Change the state of the post to "review". The post is immediately
        removed from feeds. Posts that are already in "review" state will not
        change.
      parameters:
        - name: content_id
          in: path
          description: ID or UUID of the content post
          required: true
          schema:
            type: integer
      responses:
        '200':
          description: Content Moved to Review State
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    $ref: '#/components/schemas/Content.Post.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          $ref: '#/components/responses/Common.Response.UnauthenticatedError'
        '403':
          $ref: '#/components/responses/Common.Response.UnauthorizedError'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - content.write
        - oauth2_as_a_server:
            - content.write
      x-swagger-router-controller: publishing
  /v2/content/{content_id}/comments:
    get:
      operationId: listContentComments
      tags:
        - Content Publishing
      summary: List the comments on a content post
      description: >-
        List the comments on a content post. Only top-level comments are
        returned. Comments which are replies to other comments are not currently
        available through this endpoint.
      parameters:
        - name: content_id
          in: path
          description: ID or UUID of the content post
          required: true
          schema:
            type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Content.Comment.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          $ref: '#/components/responses/Common.Response.UnauthenticatedError'
        '403':
          $ref: '#/components/responses/Common.Response.UnauthorizedError'
      security:
        - oauth2_as_a_user:
            - content.read
        - oauth2_as_a_server:
            - content.read
      x-swagger-router-controller: publishing
  /v2/content/{content_id}/comments/{comment_id}/replies:
    get:
      operationId: listContentCommentReplies
      tags:
        - Content Publishing
      summary: List the replies on comment post
      description: List the replies on comment post.
      parameters:
        - name: content_id
          in: path
          description: ID or UUID of the content post
          required: true
          schema:
            type: integer
        - name: comment_id
          in: path
          description: ID or UUID of the comment thread
          required: true
          schema:
            oneOf:
              - type: integer
              - type: string
                format: uuid
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Content.Comment.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          $ref: '#/components/responses/Common.Response.UnauthenticatedError'
        '403':
          $ref: '#/components/responses/Common.Response.UnauthorizedError'
      security:
        - oauth2_as_a_user:
            - content.read
        - oauth2_as_a_server:
            - content.read
      x-swagger-router-controller: publishing
  /v2/content/{content_id}/images:
    put:
      operationId: addContentImage
      tags:
        - Content Publishing
      summary: Add an image to a content post
      description: >-
        Add a new image to a content record. Response body is the updated
        content record. Note: This API does not resize or rehost images. Images
        should be appropriately sized and will be served from the provided URL.
      parameters:
        - name: content_id
          in: path
          description: ID or UUID of the content post
          required: true
          schema:
            type: integer
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                image_url:
                  description: URL of the image to add.
                  type: string
      responses:
        '201':
          description: Content Image Created
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Content.Image.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          $ref: '#/components/responses/Common.Response.UnauthenticatedError'
        '403':
          $ref: '#/components/responses/Common.Response.UnauthorizedError'
      security:
        - oauth2_as_a_user:
            - content.write
        - oauth2_as_a_server:
            - content.write
      x-swagger-router-controller: publishing
  /v2/content/{content_id}/videos:
    put:
      operationId: addContentVideo
      tags:
        - Content Publishing
      summary: Add a video for use in content of type article
      description: >-
        Add a new video to a content record. Response body is the attributes of
        the video record. Insert the returned <code>embed_html</code> into the
        <code>body</code> of the article at the location you want the video to
        appear in the article.
      parameters:
        - name: content_id
          in: path
          description: ID or UUID of the content post
          required: true
          schema:
            type: integer
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                video_url:
                  description: URL of the video to add.
                  type: string
                  example: https://some.video.url
                caption:
                  description: Video caption
                  type: string
                  example: Watch out!
                preview_image_url:
                  description: Video preview image URL
                  type: string
                  example: https://preview_image.video.url
              required:
                - video_url
      responses:
        '201':
          description: Content Video Added
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Content.Video.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          $ref: '#/components/responses/Common.Response.UnauthenticatedError'
        '403':
          $ref: '#/components/responses/Common.Response.UnauthorizedError'
      security:
        - oauth2_as_a_user:
            - content.write
        - oauth2_as_a_server:
            - content.write
      x-swagger-router-controller: publishing
  /v2/content/{content_id}/images/{content_image_id}:
    delete:
      operationId: removeContentImage
      tags:
        - Content Publishing
      summary: Remove an image from a content post
      description: >-
        Remove an image from a content record. Images cannot be removed from
        published content. Response status for removed content is 204 No
        Content.
      parameters:
        - name: content_id
          in: path
          description: ID or UUID of the content post
          required: true
          schema:
            type: integer
        - name: content_image_id
          in: path
          required: true
          description: ID of the content image
          schema:
            type: integer
      responses:
        '204':
          description: Success
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          $ref: '#/components/responses/Common.Response.UnauthenticatedError'
        '403':
          $ref: '#/components/responses/Common.Response.UnauthorizedError'
      security:
        - oauth2_as_a_user:
            - content.write
        - oauth2_as_a_server:
            - content.write
      x-swagger-router-controller: publishing
  /v2/content/replications:
    get:
      operationId: listContentReplications
      tags:
        - Content Publishing
      summary: Fetch content replications
      description: >-
        The endpoint allow users to get details of content replication. Source
        or target filter is required
      parameters:
        - name: filter.source.contentId
          description: >-
            ID of source content. If present then source platform should also be
            present
          in: query
          schema:
            type: integer
        - name: filter.source.platform
          description: >-
            Source platform type. If present then source content ID should also
            be present
          in: query
          schema:
            type: string
            enum:
              - firstup
              - slack
              - sharepoint
        - name: filter.target.contentId
          description: >-
            ID of published content. If present then target platform should also
            be present
          in: query
          required: false
          schema:
            type: string
        - name: filter.target.platform
          description: >-
            Target platform type. If present then target content ID should also
            be present
          in: query
          required: false
          schema:
            type: string
            enum:
              - firstup
              - slack
              - sharepoint
        - name: filter.workflowId
          description: ID of workflow
          in: query
          required: false
          schema:
            type: string
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    type: array
                    items:
                      type: object
                      properties:
                        sourceContentId:
                          type: string
                        sourcePlatform:
                          type: string
                        targetContentId:
                          type: string
                        targetPlatform:
                          type: string
                        replicatedAt:
                          type: string
                        targetLocationId:
                          type: string
                        workflowId:
                          type: integer
                example: |
                  [{
                    "sourceContentId": "3",
                    "sourcePlatform": "firstup",
                    "targetContentId": "1",
                    "targetPlatform": "firstup",
                    "replicatedAt": "2000-01-01T00:00:00Z",
                    "targetLocationId": "10",
                    "workflowId": 2
                  }, {
                    "sourceContentId": "4",
                    "sourcePlatform": "firstup",
                    "targetContentId": "723",
                    "targetPlatform": "slack",
                    "publicationDate": "2020-01-01T00:00:00Z",
                    "targetLocationId": "47",
                    "workflowId": 7
                  }]
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          $ref: '#/components/responses/Common.Response.UnauthenticatedError'
        '403':
          $ref: '#/components/responses/Common.Response.UnauthorizedError'
        '422':
          description: Validation Failed
      security:
        - oauth2_as_a_user:
            - content.read
            - content.replication.audit
        - oauth2_as_a_server:
            - content.read
            - content.replication.audit
      x-swagger-router-controller: publishing
  /v2/videos/{video_id}/download:
    get:
      operationId: downloadContentVideo
      tags:
        - Content Publishing
      summary: Get a download URL for a content video
      description: Returns a temporary link to a content video.
      parameters:
        - name: video_id
          description: ID of the video
          in: path
          required: true
          schema:
            type: integer
        - name: lifespan
          description: >-
            Number of seconds the link should remain valid from the time it is
            generated
          in: query
          required: false
          schema:
            type: integer
            format: int32
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    type: object
                    properties:
                      video_id:
                        type: integer
                        description: ID of the video
                        example: 628
                      download_url:
                        type: string
                        example: https://cdn.example.com/acme/acmetimes/video/cab13
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      x-swagger-router-controller: publishing
      security:
        - oauth2_as_a_user:
            - content.videos.download
        - oauth2_as_a_server:
            - content.videos.download
  /v2/content/{content_id}/reach/unique_user_count:
    get:
      operationId: contentReachCount
      tags:
        - Content Publishing
      summary: Fetch the unique count of users who can see the content post
      description: >-
        Fetch the content reach, the unique user count for audiences, topics,
        and both.
      parameters:
        - name: content_id
          in: path
          description: ID of the content post
          required: true
          schema:
            type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    type: object
                    properties:
                      content_id:
                        type: integer
                        example: 1
                      unique_user_count:
                        type: object
                        properties:
                          total:
                            type: integer
                            description: Total unique user count
                            example: 700
                          topic:
                            type: integer
                            description: Unique user count from topic settings
                            example: 300
                          audience:
                            type: integer
                            description: Unique user count from audience settings
                            example: 500
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - content.read
        - oauth2_as_a_server:
            - content.read
      x-swagger-router-controller: publishing
  /scim/v2/Schemas:
    get:
      operationId: listSchemas
      tags:
        - User Management
      summary: List SCIM schemas
      description: >
        Returns a list of the schemas in use by this SCIM API. Implements <a
        href="https://tools.ietf.org/html/rfc7643#section-7">SCIM 2.0
        Specification</a>.
      responses:
        '200':
          description: Success
          content:
            application/scim+json:
              schema:
                type: object
                properties:
                  schemas:
                    type: array
                    items:
                      type: string
                    example:
                      - urn:ietf:params:scim:api:messages:2.0:ListResponse
                  totalResults:
                    type: integer
                    example: 5
                  itemsPerPage:
                    type: integer
                    example: 10
                  startIndex:
                    type: integer
                    example: 1
                  Resources:
                    type: array
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                          example: urn:ietf:params:scim:schemas:core:2.0:User
                        name:
                          type: string
                          example: SCIMCoreUser
                        description:
                          type: string
                          example: SCIM Core User
                        meta:
                          type: object
                          properties:
                            resourceType:
                              type: string
                              example: Schema
                            location:
                              type: string
                              example: >-
                                https://partner.socialchorus.com/scim/v2/Schemas/urn:ietf:params:scim:schemas:core:2.0:User
                        attributes:
                          type: array
                          items:
                            type: object
                    example:
                      - id: urn:ietf:params:scim:schemas:core:2.0:User
                        name: SCIMCoreUser
                        description: SCIM Core User
                        attributes:
                          - Array
                      - id: >-
                          urn:ietf:params:scim:schemas:extension:enterprise:2.0:User
                        name: EnterpriseUser
                        description: Enterprise User
                        attributes:
                          - Array
                      - id: urn:SocialChorus:1.0:User
                        name: SocialChorusUserExtension
                        description: Social Chorus User Extension
                        attributes:
                          - Array
        '401':
          $ref: '#/components/responses/Scim.Error.401'
        '403':
          $ref: '#/components/responses/Scim.Error.403'
      x-swagger-router-controller: scim
      security:
        - oauth2_as_a_server:
            - users.read
        - oauth2_as_a_user:
            - users.read
  /scim/v2/Schemas/{schema_id}:
    get:
      operationId: detailSchema
      tags:
        - User Management
      summary: Detail a SCIM schema
      description: >
        Returns the specified schema used by this SCIM API. Implements <a
        href="https://tools.ietf.org/html/rfc7643#section-7">SCIM 2.0
        specification</a>.
      parameters:
        - name: schema_id
          description: The Schema ID.
          in: path
          required: true
          schema:
            type: string
      responses:
        '200':
          description: Success
          content:
            application/scim+json:
              schema:
                type: object
                example: |
                  {
                    "id": "urn:SocialChorus:1.0:User",
                    "name": "SocialChorusUserExtension",
                    "description": "Social Chorus User Extension",
                    "attributes": [
                      {
                        "caseExact": false,
                        "description": "The user's business unit.",
                        "multiValued": false,
                        "mutability": "readWrite",
                        "name": "businessUnit",
                        "required": false,
                        "returned": "default",
                        "type": "string",
                        "uniqueness": "none"
                      },
                      {
                        "caseExact": false,
                        "description": "The user's gender.",
                        "multiValued": false,
                        "mutability": "readWrite",
                        "name": "gender",
                        "required": false,
                        "returned": "default",
                        "type": "string",
                        "uniqueness": "none"
                      },
                      {
                        "caseExact": false,
                        "description": "The user's manager's name.",
                        "multiValued": false,
                        "mutability": "readWrite",
                        "name": "managerName",
                        "required": false,
                        "returned": "default",
                        "type": "string",
                        "uniqueness": "none"
                      },
                      {
                        "caseExact": false,
                        "description": "The user's work location.",
                        "multiValued": false,
                        "mutability": "readWrite",
                        "name": "workLocation",
                        "required": false,
                        "returned": "default",
                        "type": "string",
                        "uniqueness": "none"
                      },
                      {
                        "caseExact": false,
                        "description": "The user's birth date.",
                        "multiValued": false,
                        "mutability": "readWrite",
                        "name": "birthDate",
                        "required": false,
                        "returned": "default",
                        "type": "string",
                        "uniqueness": "none"
                      },
                      {
                        "caseExact": false,
                        "description": "The user's start of employment date.",
                        "multiValued": false,
                        "mutability": "readWrite",
                        "name": "hireDate",
                        "required": false,
                        "returned": "default",
                        "type": "string",
                        "uniqueness": "none"
                      },
                      {
                        "caseExact": false,
                        "description": "The user's promotion date.",
                        "multiValued": false,
                        "mutability": "readWrite",
                        "name": "promotionDate",
                        "required": false,
                        "returned": "default",
                        "type": "string",
                        "uniqueness": "none"
                      },
                      {
                        "caseExact": false,
                        "description": "The requisition approval date.",
                        "multiValued": false,
                        "mutability": "readWrite",
                        "name": "requisitionApprovalDate",
                        "required": false,
                        "returned": "default",
                        "type": "string",
                        "uniqueness": "none"
                      },
                      {
                        "caseExact": false,
                        "description": "An array of objects including a name and value. These are stored as an arbitrary additional list of attributes associated to the user and can be used to create Groups and audiences in the Firstup platform. Currently, Custom Attributes can only be string values.",
                        "multiValued": true,
                        "mutability": "readWrite",
                        "name": "customAttributes",
                        "required": false,
                        "returned": "default",
                        "type": "complex",
                        "uniqueness": "none",
                        "subAttributes": [Array]
                      }
                    ]
                  }
        '401':
          $ref: '#/components/responses/Scim.Error.401'
        '403':
          $ref: '#/components/responses/Scim.Error.403'
        '404':
          $ref: '#/components/responses/Scim.Error.404'
      x-swagger-router-controller: scim
      security:
        - oauth2_as_a_server:
            - users.read
        - oauth2_as_a_user:
            - users.read
  /scim/v2/ServiceProviderConfig:
    get:
      operationId: detailServiceProviderConfig
      tags:
        - User Management
      summary: Provides SCIM Schema Provider Configuration
      description: >
        Returns the Schema Provider configuration as per <a
        href="https://tools.ietf.org/html/rfc7643#section-5">SCIM 2.0
        Specification</a>.

        Additional references:

        <ul>
          <li><a href="https://tools.ietf.org/html/rfc7643#section-8.5">SCIM 2.0 Spc Section 8.5</a></li>
          <li><a href="https://tools.ietf.org/html/rfc7643#section-8.7.2">SCIM 2.0 Spec Section 8.7.2</a></li>
        </ul>
      responses:
        '200':
          description: Success
          content:
            application/scim+json:
              schema:
                type: object
                example: |
                  {
                    "schemas": [ "urn:ietf:params:scim:schemas:core:2.0:ServiceProviderConfig" ],
                    "documentationUri": "https://partner.socialchorus.com/endpoints",
                    "patch": { supported: true },
                    "bulk": { supported: false },
                    "filter": { supported: true },
                    "changePassword": { supported: false },
                    "sort": { supported: true },
                    "etag": { supported: false },
                    "authenticationSchemas": [
                      {
                        "name": "OAuth Bearer Token",
                        "description": "Authentication scheme using the OAuth Bearer Token Standard",
                        "specUri": "https://www.rfc-editor.org/info/rfc6750",
                        "documentationUri": "https://partner.socialchorus.com/authorization",
                        "type": "oauthbearertoken",
                        "primary": true
                      }
                    ],
                    "meta": {
                      "location": "undefined/scim/v2/ServiceProviderConfig",
                      "resourceType": "ServiceProviderConfig",
                      "created": "2020-10-19T00:00:00Z",
                      "lastModified": "2020-10-19T00:00:00Z",
                      "version": "v1.22.1"
                    }
                  }
        '401':
          $ref: '#/components/responses/Scim.Error.401'
        '403':
          $ref: '#/components/responses/Scim.Error.403'
      x-swagger-router-controller: scim
      security:
        - oauth2_as_a_server:
            - users.read
        - oauth2_as_a_user:
            - users.read
  /scim/v2/ResourceTypes:
    get:
      operationId: listResourceTypes
      tags:
        - User Management
      summary: Provides SCIM Resource Types
      description: >
        Returns available Resource Types configuration as per <a
        href="https://tools.ietf.org/html/rfc7643#section-5">SCIM 2.0
        Specification</a>.

        Additional references:

        <ul>
          <li><a href="https://tools.ietf.org/html/rfc7644#section-4">SCIM 2.0 Protocol Spec Section 4</a></li>
          <li><a href="https://tools.ietf.org/html/rfc7643#section-8.6">SCIM 2.0 Spec Section 8.5</a></li>
        </ul>
      responses:
        '200':
          description: Success
          content:
            application/scim+json:
              schema:
                type: object
                example: |
                  {
                    "totalResults": 1,
                    "itemsPerPage": 1,
                    "startIndex": 1,
                    "schemas": [ "urn:ietf:params:scim:api:messages:2.0:ListResponse" ],
                    "Resources": [
                      {
                        "schemas": [Array],
                        "id": "User",
                        "name": "User",
                        "endpoint": "/scim/v2/Users",
                        "description": "User Account",
                        "schema": "urn:ietf:params:scim:schemas:core:2.0:User",
                        "schemaExtensions": [Array],
                        "meta": [Object]
                      }
                    ]
                  }
        '401':
          $ref: '#/components/responses/Scim.Error.401'
        '403':
          $ref: '#/components/responses/Scim.Error.403'
      x-swagger-router-controller: scim
      security:
        - oauth2_as_a_server:
            - users.read
        - oauth2_as_a_user:
            - users.read
  /scim/v2/ResourceTypes/{resource_id}:
    get:
      operationId: detailResourceType
      tags:
        - User Management
      summary: Detail a SCIM Resource Type
      description: >
        Returns the requested Resource Type <a
        href="https://tools.ietf.org/html/rfc7643#section-5">SCIM 2.0
        Specification</a>.

        Additional references:

        <ul>
          <li><a href="https://tools.ietf.org/html/rfc7644#section-4">SCIM 2.0 Protocol Spec Section 4</a></li>
          <li><a href="https://tools.ietf.org/html/rfc7643#section-8.6">SCIM 2.0 Spec Section 8.5</a></li>
        </ul>
      parameters:
        - name: resource_id
          description: The Resource ID.
          in: path
          required: true
          schema:
            type: string
      responses:
        '200':
          description: Success
          content:
            application/scim+json:
              schema:
                type: object
                example: |
                  {
                    "schemas": [ "urn:ietf:params:scim:schemas:core:2.0:ResourceType" ],
                    "id": "User",
                    "name": "User",
                    "endpoint": "/scim/v2/Users",
                    "description": "User Account",
                    "schema": "urn:ietf:params:scim:schemas:core:2.0:User",
                    "schemaExtensions": [
                      {
                        "schema": "urn:ietf:params:scim:schemas:extension:enterprise:2.0:User",
                        "required": true
                      },
                      {
                        "schema": "urn:SocialChorus:1.0:User",
                        "required": true
                      }
                    ],
                    "meta": {
                      "location": "undefined/v2/ResourceTypes/User",
                      "resourceType": "ResourceType"
                    }
                  }
        '401':
          $ref: '#/components/responses/Scim.Error.401'
        '403':
          $ref: '#/components/responses/Scim.Error.403'
      x-swagger-router-controller: scim
      security:
        - oauth2_as_a_server:
            - users.read
        - oauth2_as_a_user:
            - users.read
  /scim/v2/Groups:
    get:
      operationId: listGroups
      tags:
        - User Groups
      summary: Returns a list of Groups
      description: |
        Returns a list of all accessible Groups in the acting User's Program.
      parameters:
        - in: query
          name: startIndex
          required: false
          description: |

            Specifies the 1-based index of the page of results to be returned.
          schema:
            type: integer
        - in: query
          name: count
          required: false
          description: |

            Specifies the maximum number of results to be returned.
          schema:
            type: integer
      responses:
        '200':
          description: Success
          content:
            application/scim+json:
              schema:
                type: object
                properties:
                  schemas:
                    type: array
                    items:
                      type: string
                    example:
                      - urn:ietf:params:scim:api:messages:2.0:ListResponse
                  Resources:
                    type: array
                    items:
                      $ref: '#/components/schemas/Scim.Group.Resource'
        '400':
          $ref: '#/components/responses/Scim.Error.400'
        '401':
          $ref: '#/components/responses/Scim.Error.401'
        '403':
          $ref: '#/components/responses/Scim.Error.403'
        '404':
          $ref: '#/components/responses/Scim.Error.404'
      x-swagger-router-controller: scim
      security:
        - oauth2_as_a_server:
            - groups.read
        - oauth2_as_a_user:
            - groups.read
    post:
      operationId: createGroup
      tags:
        - User Groups
      summary: Creates a Group
      description: >
        Creates and provisions a new Group of Users. The request should include
        any properties to be set on

        the Group. Any property not provided would leave the value blank or use
        defaults.


        The list of members could be empty or not present. Members are
        referenced with the `identifierField`,

        by either:

        - `email`

        - `id`

        - `userName` (the default if no `identifierField` is included)


        This operation is asynchronous, the response will not include the list
        of members.


        A `JobId` will be in the response's meta, to be able to get a JobReport
        (see the ad hoc endpoint below).


        Indexing a Group's Users can take some time.
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Scim.Group.CreateRequestBody'
      responses:
        '201':
          description: Group created
          content:
            application/scim+json:
              schema:
                allOf:
                  - type: object
                    properties:
                      schemas:
                        type: array
                        description: List of Schemas
                        example:
                          - urn:ietf:params:scim:schemas:core:2.0:Group
                          - SocialChorus:1.0:Group
                        items:
                          type: string
                  - $ref: '#/components/schemas/Scim.Group.AsyncResource'
        '400':
          $ref: '#/components/responses/Scim.Error.400'
        '401':
          $ref: '#/components/responses/Scim.Error.401'
        '403':
          $ref: '#/components/responses/Scim.Error.403'
      x-swagger-router-controller: scim
      security:
        - oauth2_as_a_server:
            - groups.write
        - oauth2_as_a_user:
            - groups.write
  /scim/v2/Groups/{group_id}:
    get:
      operationId: detailGroup
      tags:
        - User Groups
      summary: Returns the details of the given Group, including its members
      description: >

        Returns the group specified by the `group_id`. Groups are defined by the
        [SCIM
        specification](https://datatracker.ietf.org/doc/html/rfc7643#section-4.2).
      parameters:
        - name: group_id
          description: ID of the group to look up.
          in: path
          required: true
          schema:
            type: string
      responses:
        '200':
          description: Success
          content:
            application/scim+json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/Scim.Group.Resource'
                  - type: object
                    properties:
                      schemas:
                        type: array
                        items:
                          type: string
                          example: urn:ietf:params:scim:schemas:core:2.0:Group
        '400':
          $ref: '#/components/responses/Scim.Error.400'
        '401':
          $ref: '#/components/responses/Scim.Error.401'
        '403':
          $ref: '#/components/responses/Scim.Error.403'
        '404':
          $ref: '#/components/responses/Scim.Error.404'
      x-swagger-router-controller: scim
      security:
        - oauth2_as_a_server:
            - groups.read
        - oauth2_as_a_user:
            - groups.read
    patch:
      operationId: patchGroup
      tags:
        - User Groups
      summary: Updates a Group
      description: >
        Update an audience in the Program with partial changes using

        [SCIM PatchOp](https://tools.ietf.org/html/rfc7644#section-3.5.2).


        Add or remove selected fields of the audience.


        The list of members in the Group is referenced using the
        `identifierField`, by either:

        - `email`

        - `id`

        - `userName` (the default if no `identifierField` is included)


        All operations are supported: `add`, `remove`, and `replace`.


        Note that a `replace` will replace all the members of the Group by the
        value sent

        (a full replace).


        This operation is asynchronous, the response will not include the list
        of members.


        A `JobId` will be in the response's meta, to be able to get a JobReport
        (see the ad hoc endpoint below).


        See the [SCIM Patch Operation
        guide](/usermanagementapi/scim-patch-operations) for more details.
      parameters:
        - in: path
          name: group_id
          description: ID of the audience to patch
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Scim.Group.PatchRequestBody'
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                allOf:
                  - type: object
                    properties:
                      schemas:
                        type: array
                        description: List of Schemas
                        example:
                          - urn:ietf:params:scim:schemas:core:2.0:Group
                          - SocialChorus:1.0:Group
                        items:
                          type: string
                  - $ref: '#/components/schemas/Scim.Group.AsyncResource'
        '400':
          $ref: '#/components/responses/Scim.Error.400'
        '401':
          $ref: '#/components/responses/Scim.Error.401'
        '403':
          $ref: '#/components/responses/Scim.Error.403'
        '404':
          $ref: '#/components/responses/Scim.Error.404'
      x-swagger-router-controller: scim
      security:
        - oauth2_as_a_server:
            - groups.write
        - oauth2_as_a_user:
            - groups.write
    delete:
      operationId: deleteGroup
      tags:
        - User Groups
      summary: Deletes a Group
      description: |
        Delete an audience in the Program
      parameters:
        - in: path
          name: group_id
          description: ID of the audience to patch
          required: true
          schema:
            type: string
      responses:
        '204':
          description: Deleted
        '400':
          $ref: '#/components/responses/Scim.Error.400'
        '401':
          $ref: '#/components/responses/Scim.Error.401'
        '403':
          $ref: '#/components/responses/Scim.Error.403'
      x-swagger-router-controller: scim
      security:
        - oauth2_as_a_server:
            - groups.write
        - oauth2_as_a_user:
            - groups.write
    put:
      operationId: updateGroup
      tags:
        - User Groups
      summary: Updates a Group
      description: >
        Updates and provisions an existing Group of Users. The request should
        include any properties to be set on

        the Group. Any property not provided would leave the value blank or use
        defaults.


        The list of members could be empty or not present. Members are
        referenced with the `identifierField`,

        by either:

        - `email`

        - `id`

        - `userName` (the default if no `identifierField` is included)


        This operation is asynchronous, the response will not include the list
        of members.


        A `JobId` will be in the response's meta, to be able to get a JobReport
        (see the ad hoc endpoint below).


        Indexing a Group's Users can take some time.
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Scim.Group.UpdateRequestBody'
      responses:
        '200':
          description: Group updated
          content:
            application/scim+json:
              schema:
                allOf:
                  - type: object
                    properties:
                      schemas:
                        type: array
                        description: List of Schemas
                        example:
                          - urn:ietf:params:scim:schemas:core:2.0:Group
                          - SocialChorus:1.0:Group
                        items:
                          type: string
                  - $ref: '#/components/schemas/Scim.Group.AsyncResource'
        '400':
          $ref: '#/components/responses/Scim.Error.400'
        '401':
          $ref: '#/components/responses/Scim.Error.401'
        '403':
          $ref: '#/components/responses/Scim.Error.403'
      x-swagger-router-controller: scim
      security:
        - oauth2_as_a_server:
            - groups.write
        - oauth2_as_a_user:
            - groups.write
  /v2/Groups/JobReport/{jobId}:
    get:
      operationId: groupAsyncJobReport
      tags:
        - User Groups
      summary: Returns details on asynchronous jobs to modify a Group's members
      description: >
        The calls to the POST, PUT or PATCH `Groups Managements` endpoints
        trigger a series of asynchronous jobs to create or update the list of
        the Group's members.


        As these tasks are asynchronous, those API calls do not respond with the
        final list of the Group's members, but an unique Job identifier to
        inquire about the task.


        This endpoint takes the `jobId` identifier, and returns details about
        the asynchronous job's execution.


        The job could have already finished or still be running, and the
        response could include details on the number of members added, removed,
        processed, and error conditions (if any).
      parameters:
        - name: jobId
          in: path
          description: The unique identifier of one asynchronous Job
          required: true
          schema:
            type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: integer
                    description: Job unique identifier
                    example: 127
                  groupId:
                    type: integer
                    description: Group unique identifier
                    example: 3242
                  status:
                    type: string
                    description: >-
                      Whether the asynchronous job is still ongoing or it has
                      finished
                    example: finished
                  requestType:
                    type: string
                    description: The type of request that launched the asynchronous job
                    example: group_update
                  requestedChanges:
                    type: string
                    description: >-
                      JSON string wih details of the number of members to be
                      changed by the API request
                    example: '{"create":4,"destroy":7}'
                  requestReceivedAt:
                    type: string
                    description: Date and time when the asynchronous job was launched
                    example: '2024-04-11T12:59:28.043Z'
                  membersCreatedCount:
                    type: integer
                    description: Number of members added to the group
                    example: 0
                  membersRemovedCount:
                    type: integer
                    description: Number of members removed from the group
                    example: 1
                  membersProcessedCount:
                    type: integer
                    description: >
                      Number of members processed. It could include additions,
                      removals, or users ignored (for example, for being already
                      in the group, or not being members of the program)
                    example: 11
                  membersPendingCount:
                    type: integer
                    description: Number of members pending to the processed
                    example: 0
                  messages:
                    type: string
                    description: >
                      Additional details compiled during the job's execution, if
                      any relevant applies, specially those related to the total
                      number of members processed. For example: number of users
                      not considered, for already being members, or users asked
                      to be both added and removed, or system errors...
                    example: >-
                      4 user(s) not added (already members?); 6 user(s) not
                      removed (not members?)
        '400':
          $ref: '#/components/responses/Scim.Error.400'
        '401':
          $ref: '#/components/responses/Scim.Error.401'
        '403':
          $ref: '#/components/responses/Scim.Error.403'
        '404':
          $ref: '#/components/responses/Scim.Error.404'
      x-swagger-router-controller: scim
      security:
        - oauth2_as_a_server:
            - groups.read
        - oauth2_as_a_user:
            - groups.read
  /scim/v2/Users:
    get:
      operationId: listUsers
      tags:
        - User Management
      summary: List users in the program
      description: >
        This endpoint allows you to retrieve information about all or some of
        the

        users stored in the Firstup application and adheres to the

        [SCIM 2.0 Section:
        4.1](https://datatracker.ietf.org/doc/html/rfc7643#section-4.1)
        standard.


        &#128218; For more in-depth guidance on using the user interface and

        understanding the application's behavior, you can refer to the user

        documentation provided

        [here](https://support.firstup.io/hc/en-us/articles/4834506731543-Manually-Add-or-Import-Users).

        This documentation will help bridge the gap between

        the API and the intricacies of Firstup.
      parameters:
        - in: query
          name: filter
          required: false
          description: >
            Supports a

            [SCIM filter
            expression](https://tools.ietf.org/html/rfc7644#section-3.4.2.2)

            allowing for filtering the results based on specific criteria, such
            as

            userName or role.


            Supported operator: `eq`


            **Supported Fields:**


            * `userName`: internally maps to federated_identifier.

            * `role`: either new or legacy roles depending on program
            configuration.


            **Examples**:

            * `userName eq "user123"` (URL encoded:
            `?filter=userName%20eq%20%22user123%22`)

            * `role eq "publisher"` (URL encoded:
            `?filter=role%20eq%20%22publisher%22`)
          schema:
            type: string
        - in: query
          name: startIndex
          required: false
          description: >
            <a href="https://tools.ietf.org/html/rfc7644#section-3.4.2.4">SCIM
            pagination parameter</a>

            1-based offset of the first query result
          schema:
            type: integer
        - in: query
          name: count
          required: false
          description: >
            <a href="https://tools.ietf.org/html/rfc7644#section-3.4.2.4">SCIM
            pagination parameter</a>

            Total number of results returned
          schema:
            type: integer
      responses:
        '200':
          description: Success
          content:
            application/scim+json:
              schema:
                type: object
                properties:
                  schemas:
                    type: array
                    items:
                      type: string
                    example:
                      - urn:ietf:params:scim:api:messages:2.0:ListResponse
                  totalResults:
                    type: integer
                    example: 5
                  itemsPerPage:
                    type: integer
                    example: 10
                  startIndex:
                    type: integer
                    example: 1
                  Resources:
                    type: array
                    items:
                      $ref: '#/components/schemas/Scim.User.Resource'
        '400':
          $ref: '#/components/responses/Scim.Error.400'
        '401':
          $ref: '#/components/responses/Scim.Error.401'
        '403':
          $ref: '#/components/responses/Scim.Error.403'
        '404':
          $ref: '#/components/responses/Scim.Error.404'
      x-swagger-router-controller: scim
      security:
        - oauth2_as_a_server:
            - users.read
        - oauth2_as_a_user:
            - users.read
    post:
      operationId: createUser
      tags:
        - User Management
      summary: Create a user in the program
      description: >
        Create and provision a new user. The request should include any
        properties to be set on the user, and leaving any out will leave those
        values blank, or will use defaults. <br><br> New users have a role of
        "member" by default. New users have an onboarding status of "created" by
        default. <br><br> Setting a user's role requires that the acting user
        have a role the same or less than the role of the user being created.
        The role property is also formatted as an array to comply with SCIM
        protocol though it only accepts a single value. Providing more than one
        value will result in a 400 response.
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Scim.User.CreateRequestBody'
      responses:
        '201':
          description: User created
          content:
            application/scim+json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/Scim.User.Resource'
                  - type: object
                    properties:
                      schemas:
                        type: array
                        items:
                          type: string
                          example: urn:ietf:params:scim:schemas:core:2.0:User
        '400':
          $ref: '#/components/responses/Scim.Error.400'
        '401':
          $ref: '#/components/responses/Scim.Error.401'
        '403':
          $ref: '#/components/responses/Scim.Error.403'
        '422':
          $ref: '#/components/responses/Scim.Error.422'
      x-swagger-router-controller: scim
      security:
        - oauth2_as_a_server:
            - users.write
        - oauth2_as_a_user:
            - users.write
  /scim/v2/Users/{user_id}:
    get:
      operationId: detailUser
      tags:
        - User Management
      summary: Show a single program user by ID
      description: Returns a User record for specified user in the program.
      parameters:
        - name: user_id
          description: >
            Identifier of the user to look up. It could be used either the
            user's id, federated identifier, an email address, or external Id.
            The look up will be done in the above mentioned order.
          in: path
          required: true
          schema:
            type: string
      responses:
        '200':
          description: Success
          content:
            application/scim+json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/Scim.User.Resource'
                  - type: object
                    properties:
                      schemas:
                        type: array
                        items:
                          type: string
                          example: urn:ietf:params:scim:schemas:core:2.0:User
        '400':
          $ref: '#/components/responses/Scim.Error.400'
        '401':
          $ref: '#/components/responses/Scim.Error.401'
        '403':
          $ref: '#/components/responses/Scim.Error.403'
        '404':
          $ref: '#/components/responses/Scim.Error.404'
      x-swagger-router-controller: scim
      security:
        - oauth2_as_a_server:
            - users.read
        - oauth2_as_a_user:
            - users.read
    put:
      operationId: replaceUser
      tags:
        - User Management
      summary: Replace a user in the program
      description: >
        To update or replace user information, ensure that your request includes
        a comprehensive set of user attributes.

        &#x26a0; Utilize **PUT** endpoints carefully. Modified data models
        caused by new features or user-defined fields may lead to data loss.

        For a seamless process, consider the following:

        1. **GET** the user record using &#128279;
        [/scim/v2/Users/{user_id}](#/User%20Management/detailUser) to retrieve
        all current attributes and objects associated with the user.

        2. Modify the values you wish to change within the retrieved user
        record.

        3. Execute the PUT call with the modified user record to ensure no
        inadvertent data removal from the application.

        Alternatively, you can opt for a &#128279;
        [PATCH](#/User%20Management/patchUser) call to selectively modify
        specific attributes without affecting others.

        &#128221; Keep in mind that when updating a user's role using
        oath2_as_a_user, the acting user must have a role that's the same as or
        higher than both the starting and ending roles of the user being
        updated.
      parameters:
        - in: path
          name: user_id
          description: ID of the user to update
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Scim.User.UpdateRequestBody'
        required: true
      responses:
        '200':
          description: Success
          content:
            application/scim+json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/Scim.User.Resource'
                  - type: object
                    properties:
                      schemas:
                        type: array
                        items:
                          type: string
                          example: urn:ietf:params:scim:schemas:core:2.0:User
        '400':
          $ref: '#/components/responses/Scim.Error.400'
        '401':
          $ref: '#/components/responses/Scim.Error.401'
        '403':
          $ref: '#/components/responses/Scim.Error.403'
      x-swagger-router-controller: scim
      security:
        - oauth2_as_a_server:
            - users.write
        - oauth2_as_a_user:
            - users.write
    patch:
      operationId: patchUser
      tags:
        - User Management
      summary: Update a user in the program
      description: >
        Update a user in the program with partial changes using <a
        href="https://tools.ietf.org/html/rfc7644#section-3.5.2">SCIM
        PatchOp</a>. Add, remove, or replace selected fields of the user. Role
        updates require the acting user's role to be the same or higher role
        than the user being updated both before and after the role update.
      parameters:
        - in: path
          name: user_id
          description: >
            Identifier of the user to patch. It could be used either the user's
            id, federated identifier, an email address, or external Id. The look
            up will be done in the above mentioned order.
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Scim.User.PatchRequestBody'
        required: true
      responses:
        '200':
          description: Success
          content:
            application/scim+json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/Scim.User.Resource'
                  - type: object
                    properties:
                      schemas:
                        type: array
                        items:
                          type: string
                          example: urn:ietf:params:scim:schemas:core:2.0:User
        '400':
          $ref: '#/components/responses/Scim.Error.400'
        '401':
          $ref: '#/components/responses/Scim.Error.401'
        '403':
          $ref: '#/components/responses/Scim.Error.403'
      x-swagger-router-controller: scim
      security:
        - oauth2_as_a_server:
            - users.write
        - oauth2_as_a_user:
            - users.write
    delete:
      operationId: deleteUser
      tags:
        - User Management
      summary: Completely remove a user from the system
      description: >
        Permanently remove a User and their details from all Programs.

        A non-existent user, or a user that's already been forgotten, will
        return a 204.
      parameters:
        - in: path
          name: user_id
          description: >
            Identifier of the user to delete. It could be used either the user's
            id, federated identifier, an email address, or external Id. The look
            up will be done in the above mentioned order.
          required: true
          schema:
            type: string
      responses:
        '204':
          description: Success
        '400':
          $ref: '#/components/responses/Scim.Error.400'
        '401':
          $ref: '#/components/responses/Scim.Error.401'
        '403':
          $ref: '#/components/responses/Scim.Error.403'
        '404':
          $ref: '#/components/responses/Scim.Error.404'
      x-swagger-router-controller: scim
      security:
        - oauth2_as_a_server:
            - users.write
        - oauth2_as_a_user:
            - users.write
  /scim/v2/Users/me:
    get:
      operationId: me
      tags:
        - User Management
      summary: Show information about the current user
      description: >
        <p>Returns a User record for specified user in the program.</p> <br>
        <p><strong>Note:</strong> Customers can't use Client Credentials auth
        for this endpoint.</p>
      responses:
        '200':
          description: Success
          content:
            application/scim+json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/Scim.User.Resource'
                  - type: object
                    properties:
                      schemas:
                        type: array
                        items:
                          type: string
                          example: urn:ietf:params:scim:schemas:core:2.0:User
        '400':
          $ref: '#/components/responses/Scim.Error.400'
        '401':
          $ref: '#/components/responses/Scim.Error.401'
        '403':
          $ref: '#/components/responses/Scim.Error.403'
        '404':
          $ref: '#/components/responses/Scim.Error.404'
      x-swagger-router-controller: scim
  /v2/Users/{user_id}/forget:
    post:
      operationId: forgetUser
      tags:
        - User Management
      summary: Completely remove a user from the system (Not SCIM compliant)
      description: >
        Permanently remove a User and their details from all Programs.

        A non-existent user, or a user that's already been forgotten, will
        return a 202.
      parameters:
        - in: path
          name: user_id
          description: ID of the user to forget
          required: true
          schema:
            type: string
      responses:
        '202':
          description: Success
        '400':
          $ref: '#/components/responses/Scim.Error.400'
        '401':
          $ref: '#/components/responses/Scim.Error.401'
        '403':
          $ref: '#/components/responses/Scim.Error.403'
      x-swagger-router-controller: users
      security:
        - oauth2_as_a_server:
            - users.write
        - oauth2_as_a_user:
            - users.write
  /scim/v2/Roles:
    get:
      operationId: listRoles
      tags:
        - User Roles
      summary: Return a list of roles
      description: >

        Returns a list of all accessible roles in the actor's program. Only
        primary roles are currently available.
      parameters:
        - name: origin
          description: >
            Optional parameter to receive only either "custom" or "system"
            roles, using the SCIM filter form and the operator `eq`.


            Examples:

            - `?filter=origin eq "custom"` (URL-encoded as
            `?filter=origin%20eq%20%22custom%22`)

            - `?filter=origin eq "system"` (URL-encoded as
            `?filter=origin%20eq%20%22system%22`)
          in: query
          required: false
          schema:
            type: string
      responses:
        '200':
          description: Success
          content:
            application/scim+json:
              schema:
                type: object
                properties:
                  schemas:
                    type: array
                    items:
                      type: string
                    example:
                      - urn:ietf:params:scim:api:messages:2.0:ListResponse
                  Resources:
                    type: array
                    items:
                      $ref: '#/components/schemas/Scim.Role.Resource'
        '400':
          $ref: '#/components/responses/Scim.Error.400'
        '401':
          $ref: '#/components/responses/Scim.Error.401'
        '403':
          $ref: '#/components/responses/Scim.Error.403'
        '404':
          $ref: '#/components/responses/Scim.Error.404'
      x-swagger-router-controller: scim
      security:
        - oauth2_as_a_server:
            - users.read
        - oauth2_as_a_user:
            - users.read
  /v2/webhooks/subscriptions:
    get:
      operationId: listWebhookSubscriptions
      tags:
        - Webhooks
      summary: Fetch the program's configured webhook subscriptions
      description: >-
        <p>Fetchs multiple subscription records at a time, and can be paginated
        using cursor pagination. </p>
      parameters:
        - $ref: '#/components/parameters/page.size'
        - $ref: '#/components/parameters/page.number'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Webhooks.Subscription.Resource'
                  meta:
                    properties:
                      pagination:
                        $ref: '#/components/schemas/Standard.Meta.CursorPagination'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - webhooks.read
        - oauth2_as_a_server:
            - webhooks.read
      x-swagger-router-controller: webhooks
    post:
      operationId: createWebhookSubscription
      tags:
        - Webhooks
      summary: Create a new webhook subscription
      description: >
        <p>Subscriptions are configurations that define what events you want to
        receive webhooks for. A url and at least one event are required for a
        subscription. If your server requires authorization, the
        <code>authorization_header</code> property allows you to specify what
        value to send in the "Authorization" http header of every delivery to
        your url.</p> <br /> <p>More information about creating webhook
        subscriptions is available on the <a href="/webhooks#Creating">Creating
        Webhook Subscriptions</a> page, and the list of available events is
        available on the <a href="/webhooks#Event-List">Event List</a> page.</p>
        <br /> <p>The access token used when creating a subscription must have
        the <code>webhooks.write</code> <a href="authorization#Scopes">auth
        scope</a>. </p>
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Webhooks.Subscription.CreateRequestBody'
        description: Attributes of the webhook subscription to create.
      responses:
        '201':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    $ref: '#/components/schemas/Webhooks.Subscription.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - webhooks.write
        - oauth2_as_a_server:
            - webhooks.write
      x-swagger-router-controller: webhooks
  /v2/webhooks/subscriptions/{subscription_id}:
    put:
      operationId: updateWebhookSubscription
      tags:
        - Webhooks
      summary: Update an existing webhook subscription
      description: >
        <p>After creation, subscriptions can be updated to change what events
        are subscribed to, what url to send the payloads to, and other settings
        such as whether the subscription is active. Any values that can be set
        on the subscription when creating it can be updated.</p> <br /> <p>The
        update method is a patch operation, so only properties you send in the
        request will be updated on the record. The <code>events</code> property,
        however, does not support partial updates as an array. </p> <br />
        <p>The access token used when updating a subscription must have the
        <code>webhooks.write</code> <a href="authorization#Scopes">auth
        scope</a>. </p>
      parameters:
        - name: subscription_id
          in: path
          description: Id of the subscription to update
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Webhooks.Subscription.UpdateRequestBody'
        description: Attributes of the webhook subscription to update.
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    $ref: '#/components/schemas/Webhooks.Subscription.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - webhooks.write
        - oauth2_as_a_server:
            - webhooks.write
      x-swagger-router-controller: webhooks
    delete:
      operationId: deleteWebhookSubscription
      tags:
        - Webhooks
      summary: Delete a webhook subscription permanently
      description: >-
        Deactivate a webhook subscription and remove the record permanently.
        Warning: you cannot undo this action.
      parameters:
        - name: subscription_id
          in: path
          description: Id of the subscription to delete
          required: true
          schema:
            type: integer
      responses:
        '204':
          description: Success
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          $ref: '#/components/responses/Common.Response.UnauthenticatedError'
        '403':
          $ref: '#/components/responses/Common.Response.UnauthorizedError'
      x-swagger-router-controller: webhooks
      security:
        - oauth2_as_a_server:
            - webhooks.write
        - oauth2_as_a_user:
            - webhooks.write
    get:
      operationId: detailWebhookSubscription
      tags:
        - Webhooks
      summary: Fetch a single webhook subscription record
      parameters:
        - name: subscription_id
          in: path
          description: Id of the subscription to detail
          required: true
          schema:
            type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    $ref: '#/components/schemas/Webhooks.Subscription.Resource'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - webhooks.read
        - oauth2_as_a_server:
            - webhooks.read
      x-swagger-router-controller: webhooks
  /v2/webhooks/subscriptions/{subscription_id}/ping:
    post:
      operationId: pingWebhookSubscription
      tags:
        - Webhooks
      summary: Test a webhook subscription by pinging it with a sample payload
      description: >-
        More information about testing webhook subscriptions is available on the
        <a href="/webhooks#Testing">Testing Webhook Subscriptions</a> page.
      parameters:
        - name: subscription_id
          in: path
          description: Id of the subscription to ping
          required: true
          schema:
            type: integer
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    $ref: '#/components/schemas/Webhooks.Subscription.Ping'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          $ref: '#/components/responses/Common.Response.UnauthenticatedError'
        '403':
          $ref: '#/components/responses/Common.Response.UnauthorizedError'
      x-swagger-router-controller: webhooks
      security:
        - oauth2_as_a_server:
            - webhooks.read
        - oauth2_as_a_user:
            - webhooks.read
  /v2/assistant/inbox_items:
    get:
      operationId: listInboxItems
      tags:
        - Assistant Inbox
      summary: Fetch the program user's inbox
      description: <p>Fetches multiple inbox item records at a time.</p>
      deprecated: true
      parameters:
        - name: filter.categories
          in: query
          description: Limit returned records to those that match the category(s) provided.
          required: false
          style: form
          explode: false
          schema:
            type: array
            items:
              type: string
              default: any
              enum:
                - todo
                - push
                - mention
                - author
                - message_for_you
                - contributor
                - service
                - social_engagement
                - followed_channels
                - recommended_content
                - bookmarks
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    $ref: '#/components/schemas/Assistant.Inbox.Items.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - assistant.inbox.read
      x-swagger-router-controller: assistant_inbox
  /v2/assistant/todos:
    get:
      operationId: listTodos
      tags:
        - Assistant Inbox
      summary: Fetch the program user's Todos.
      description: <p>Fetches multiple Todo records at a time. </p>
      deprecated: true
      parameters:
        - name: filter.categories
          in: query
          description: Limit returned records to those that match the category(s) provided.
          required: false
          style: form
          explode: false
          schema:
            type: array
            items:
              type: string
              default: any
              enum:
                - content_acknowledgement
                - content_approval
                - poll
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    $ref: '#/components/schemas/Assistant.Inbox.Todos.Resource'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - assistant.inbox.read
            - feeds.read
            - feeds.rendered.read
      x-swagger-router-controller: assistant_inbox
  /v2/assistant/notifications:
    get:
      operationId: listNotifications
      tags:
        - Assistant Inbox
      summary: Fetch the program user's notifications.
      description: <p>Fetches multiple inbox notification records at a time. </p>
      deprecated: true
      parameters:
        - name: filter.unacknowledged
          description: Get only unacknowledged notifications
          in: query
          schema:
            type: boolean
        - name: filter.ids
          in: query
          description: Filter notifications by IDs
          style: form
          explode: false
          schema:
            type: array
            items:
              type: integer
        - $ref: '#/components/parameters/page.size'
        - $ref: '#/components/parameters/page.number'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    $ref: >-
                      #/components/schemas/Assistant.Inbox.Notifications.Resource
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - assistant.inbox.read
      x-swagger-router-controller: assistant_inbox
  /v2/assistant/notifications/{notification_id}/acknowledge:
    put:
      operationId: acknowledgeNotification
      tags:
        - Assistant Inbox
      summary: Acknowledge the program user's notification.
      description: <p>Mark the program user's notification acknowledged.</p>
      deprecated: true
      parameters:
        - name: notification_id
          in: path
          required: true
          schema:
            type: integer
      responses:
        '200':
          description: Success
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - assistant.inbox.read
      x-swagger-router-controller: assistant_inbox
  /v2/assistant/notifications/acknowledge_all:
    put:
      operationId: acknowledgeAllNotifications
      tags:
        - Assistant Inbox
      summary: Acknowledge all program user's notifications.
      description: <p>Mark all program user's notifications acknowledged.</p>
      deprecated: true
      responses:
        '200':
          description: Success
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - assistant.inbox.read
      x-swagger-router-controller: assistant_inbox
  /v2/assistant/inbox_items/total_count:
    get:
      operationId: getInboxItemsTotalCount
      tags:
        - Assistant Inbox
      summary: Fetch the program user's notifications count.
      description: <p>Fetches the count of notifications for the user.</p>
      deprecated: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    type: object
                    properties:
                      count:
                        type: integer
                        example: 1
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - assistant.inbox.read
      x-swagger-router-controller: assistant_inbox
  /v2/notification_center/notifications:
    get:
      operationId: listNotifications
      tags:
        - Notification Center
      summary: Fetch the program user's notifications.
      description: <p>Fetches multiple inbox notification records at a time. </p>
      parameters:
        - name: filter.read
          description: Get only read notifications
          in: query
          schema:
            type: boolean
        - name: filter.unread
          description: Get only unread notifications
          in: query
          schema:
            type: boolean
        - name: filter.archived
          description: Get only archived notifications
          in: query
          schema:
            type: boolean
        - name: filter.unarchived
          description: Get only unarchived notifications
          in: query
          schema:
            type: boolean
        - name: filter.important
          description: Get only important notifications
          in: query
          schema:
            type: boolean
        - name: filter.action_required
          description: Get only notifications with action required
          in: query
          schema:
            type: boolean
        - name: filter.message
          description: Get only message notifications
          in: query
          schema:
            type: boolean
        - name: filter.activity
          description: Get only activity notifications
          in: query
          schema:
            type: boolean
        - $ref: '#/components/parameters/page.size'
        - $ref: '#/components/parameters/page.number'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    $ref: >-
                      #/components/schemas/Assistant.Inbox.Notifications.Resource
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - notification_center
      x-swagger-router-controller: notification_center
  /v2/notification_center/notifications/{notification_id}/read:
    put:
      operationId: readNotification
      tags:
        - Notification Center
      summary: Acknowledge the program user's notification.
      description: <p>Mark the program user's notification read.</p>
      parameters:
        - name: notification_id
          in: path
          required: true
          schema:
            type: integer
      responses:
        '200':
          description: Success
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - notification_center
      x-swagger-router-controller: notification_center
  /v2/notification_center/total_count:
    get:
      operationId: getNotificationsTotalCount
      tags:
        - Notification Center
      summary: Fetch the program user's notifications count.
      description: <p>Fetches the count of notifications for the user.</p>
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    type: object
                    properties:
                      count:
                        type: integer
                        example: 1
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                $ref: '#/components/responses/Common.ErrorResponse'
      security:
        - oauth2_as_a_user:
            - notification_center
      x-swagger-router-controller: notification_center
servers:
  - url: /
components:
  parameters:
    page.number:
      name: page.number
      in: query
      description: Using classical pagination, the page number to return. Default is 1
      required: false
      schema:
        type: integer
        format: int64
    page.size:
      name: page.size
      in: query
      description: >-
        Return ``page.size`` number of records starting at ``size*number``.
        Default is 1, resulting in the first page being retrieved
      required: false
      schema:
        type: integer
        format: int64
  responses:
    Common.ErrorResponse:
      description: Error
      content:
        '*/*':
          schema:
            type: object
            properties:
              errors:
                type: array
                items:
                  type: object
                  properties:
                    status:
                      type: integer
                      format: int32
                    title:
                      type: string
                    detail:
                      type: string
    Common.Response.UnauthorizedError:
      description: Unauthorized
      content:
        '*/*':
          schema:
            type: object
            properties:
              errors:
                type: array
                items:
                  type: object
                  properties:
                    code:
                      type: integer
                      format: int32
                      example: 403
                    title:
                      type: string
                      example: Unauthorized
                    detail:
                      type: string
    Common.Response.UnauthenticatedError:
      description: Unauthenticated
      content:
        '*/*':
          schema:
            type: object
            properties:
              errors:
                type: array
                items:
                  type: object
                  properties:
                    code:
                      type: integer
                      format: int32
                      example: 401
                    title:
                      type: string
                      example: Unauthenticated
                    detail:
                      type: string
                      example: Access token was not provided or not recognized.
    Scim.Error.400:
      description: Bad Request
      content:
        '*/*':
          schema:
            type: object
            properties:
              schemas:
                type: array
                items:
                  type: string
                example:
                  - urn:ietf:params:scim:api:messages:2.0:Error
              detail:
                type: string
                example: Reason for bad request
              status:
                type: integer
                example: 400
    Scim.Error.422:
      description: Unprocessable Entity
      content:
        '*/*':
          schema:
            type: object
            properties:
              schemas:
                type: array
                items:
                  type: string
                example:
                  - urn:ietf:params:scim:api:messages:2.0:Error
              detail:
                type: array
                items:
                  type: object
                  properties:
                    instancePath:
                      type: string
                    schemaPath:
                      type: string
                    keyword:
                      type: string
                    params:
                      type: object
                    message:
                      type: string
              status:
                type: integer
                example: 422
    Scim.Error.401:
      description: Unauthenticated
      content:
        '*/*':
          schema:
            type: object
            properties:
              schemas:
                type: array
                items:
                  type: string
                example:
                  - urn:ietf:params:scim:api:messages:2.0:Error
              detail:
                type: string
                example: Authentication failure
              status:
                type: integer
                example: 401
    Scim.Error.403:
      description: Unauthorized
      content:
        '*/*':
          schema:
            type: object
            properties:
              schemas:
                type: array
                items:
                  type: string
                example:
                  - urn:ietf:params:scim:api:messages:2.0:Error
              detail:
                type: string
                example: Operation is not permitted
              status:
                type: integer
                example: 403
    Scim.Error.404:
      description: Not Found
      content:
        '*/*':
          schema:
            type: object
            properties:
              schemas:
                type: array
                items:
                  type: string
                example:
                  - urn:ietf:params:scim:api:messages:2.0:Error
              detail:
                type: string
                example: The requested resource was not found.
              status:
                type: integer
                example: 404
  requestBodies:
    listFeedPostsIds:
      content:
        application/json:
          schema:
            type: array
            items:
              type: integer
  securitySchemes:
    oauth2_as_a_server:
      type: oauth2
      description: OAuth2 for Server-to-Server (Client Credentials grant flow)
      flows:
        clientCredentials:
          tokenUrl: IAM_DOMAIN/oauth/token
          scopes:
            admin_login: Manage groups and other sensitive information
            public: View public information.
            users.read: View and list details of users in your program.
            users.write: Create, view, and update users in your program.
            groups.read: View and list details of groups in your program.
            groups.write: Create, view, and update groups in your program.
            content.read: View and list details of content in your program.
            content.write: Create, view, and update content in your program.
            content.videos.download: Download and play videos in content posts.
            content.replication.audit: Read content replication status.
            webhooks.read: View and list details of webhook subscriptions in your program.
            webhooks.write: Create, view, and update webhook subscriptions in your program.
    oauth2_as_a_user:
      type: oauth2
      description: OAuth2 for Users (Authorization Code grant flow)
      flows:
        authorizationCode:
          authorizationUrl: IAM_DOMAIN/oauth/authorize
          tokenUrl: IAM_DOMAIN/oauth/token
          scopes:
            admin_login: Manage groups and other sensitive information
            openid: Authenticate your account using OpenID.
            public: View public information.
            feeds.read: View your feeds.
            feeds.rendered.read: View rendered content from feed posts.
            feeds.engage: View your feeds and engage with posts (likes, bookmarks, etc).
            users.read: View and list details of users in your program.
            users.write: Create, view, and update users in your program.
            groups.read: View and list details of groups in your program.
            groups.write: Create, view, and update groups in your program.
            content.read: View and list details of content in your program.
            content.write: Create, view, and update content in your program.
            content.videos.download: Download and play videos in content posts.
            content.replication.audit: Read content replication status.
            webhooks.read: View and list details of webhook subscriptions in your program.
            webhooks.write: Create, view, and update webhook subscriptions in your program.
            assistant.inbox.read: View and list details of your assistant inbox items.
            notification_center: View and list notification center items.
  schemas:
    Feeds.Post.Resource:
      type: object
      properties:
        id:
          type: integer
          description: Unique identifier for this post
          example: 456
        uuid:
          type: string
          format: uuid
          example: 8b358e6b-11d4-4e89-bf7f-ec670e3398ed
        version:
          type: integer
          description: >
            The version of the content creation studio used to generate the
            content.

            - `1` - Legacy Studio

            - `2` - Creator Studio
          enum:
            - 1
            - 2
        content_type:
          type: string
          description: >-
            The type of content. One of: article, image, link, note, or video.
            The content_type can determine how the post should be presented. 
          example: article
        title:
          type: string
          description: The post title. Can also be considered the headline.
          example: Example Post Title
        summary:
          type: string
          description: Short summary of the post.
          example: Example Post Summary
        body:
          type: string
          description: The body of the post.
          example: Example post body
        accent_color:
          type: string
          description: The color of the post, currently only applicable to notes.
        author:
          $ref: '#/components/schemas/Content.Post.Resource.author'
        channels:
          type: array
          description: A list of the topics this post is published to.
          items:
            type: object
            properties:
              channel_id:
                type: integer
                example: 789
                description: >
                  Topic's unique identifier (GUID). <br/><br/> <b>NOTE:</b>
                  Originally called "id" in this documentation.
              name:
                type: string
                example: Name of Example Topic
                description: >
                  Topic's name. <br/><br/> <b>NOTE:</b> Originally called
                  "title" in this documentation.
        engagement:
          type: object
          properties:
            liked_at:
              type: string
              format: date-time
              description: >-
                Date and time at which the user liked the post. If the user has
                not liked the post, this value will be null.
              example: '2000-01-01T00:00:00Z'
            bookmarked_at:
              type: string
              format: date-time
              description: >-
                Date and time at which the user bookmarked the post. If the user
                has not bookmarked the post, this value will be null.
              example: '2000-01-01T00:00:00Z'
            viewed_at:
              type: string
              format: date-time
              description: >-
                Date and time at which the user viewed the post. If the user has
                not viewed the post, this value will be null.
              example: '2000-01-01T00:00:00Z'
            total_likes_count:
              type: integer
              format: int64
              description: The total likes of this post within the program by any user.
              example: 5
            total_shares_count:
              type: integer
              format: int64
              description: >-
                The total number of shares of this post within the program by
                any user.
              example: 5
            total_bookmarks_count:
              type: integer
              format: int64
              description: >-
                The total number of bookmarks this post has got within the
                program by any user.
              example: 5
        updated_at:
          type: string
          format: date-time
          description: >-
            When this content was last updated in ISO8601 format and UTC
            timezone.
          example: '2000-01-01T00:00:00Z'
        published_at:
          type: string
          format: date-time
          description: When this content was published in ISO8601 format and UTC timezone.
          example: '2000-01-01T00:00:00Z'
        visibility:
          type: string
          enum:
            - private
            - public
            - any
          description: >
            An indication of the native availability of the post within the
            Firstup platform. If 'public', the post has a public_link_url and
            shares of the post should use that url as the canonical url. If
            'private', the post requires user authentication to view.
          example: public
        featured:
          type: boolean
          description: Whether the post is featured.
          example: true
        featured_label:
          type: string
          description: The content's feature label
          example: Save Pandora!
        permalink_url:
          type: string
          description: The url of the post on the Firstup platform.
          example: https://onfirstup.com/acme/acmetimes/sc4#contents/456
        shareable_url:
          type: string
          description: >
            The publicly shareable url of the post if it's visibility is public.
            Private visibility posts will have no shareable_url.
          example: https://onfirstup.com/acme/acmetimes/sc4#contents/456
        prepopulated_share_message:
          type: string
          description: |
            The auto-generated string used when sharing the post.
          example: >-
            Example Post Title
            https://onfirstup.com/acme/acmetimes/sc4#contents/456
        appended_hashtag:
          type: string
          description: >
            The hashtag configured to be included when sharing the posts.
            example: #YourBrand
        language:
          type: string
          description: The language. For non-translatable posts, this value will be null.
          example: en
        is_translatable:
          type: boolean
          description: Whether the content is translatable.
          example: true
        is_commentable:
          type: boolean
          description: Whether the content allows comments.
          example: true
        comment_count:
          type: integer
          description: The number of comments on the content.
          example: 5
        poster_image_url:
          type: string
          description: 'The url of the primary image used for this post, if one exists. '
          example: https://cdn.example.com/acme/acmetimes/images/abc123
        links:
          type: array
          items:
            type: object
            properties:
              link_url:
                type: string
                example: https://google.com
        images:
          type: array
          items:
            $ref: '#/components/schemas/Content.Image.Resource'
        videos:
          type: array
          items:
            type: object
            properties:
              embed_html:
                type: string
                description: >
                  Html that can be used to embed the video in a page, wrapped in
                  an iframe widget.
                example: >
                  <iframe
                  href='https://onfirstup.com/acme/acmetimes/sc4#contents/456/videos/abc123'></iframe>
              link_url:
                type: string
                description: A link to the video where it can be played
                example: >-
                  https://onfirstup.com/acme/acmetimes/sc4#contents/456/videos/abc123
    Feeds.Poll.Resource:
      type: object
      properties:
        id:
          type: integer
          description: Unique identifier for this poll
          example: 456
        type:
          type: string
          example: unanswered_poll
        attributes:
          type: object
          properties:
            id:
              type: integer
              example: 1
            program_id:
              type: integer
              example: 1
            max_selections:
              type: integer
              example: 1,
            question_text:
              type: string
              example: question
            criterion:
              type: string
              example: criterion
            preset:
              type: string
              example: preset
            publish_at:
              type: string
              format: date-time
              example: '2000-01-01T00:00:00Z'
            archive_at:
              type: string
              format: date-time
              example: '2000-01-01T00:00:00Z'
            status:
              type: string
              example: published
            description_text:
              type: string
              example: description text
            selection:
              type: string
              example: selection
            selection_type:
              type: string
              example: selection type
            total_audience:
              type: integer
              example: 1
            show_results_to_user:
              type: boolean
              example: true
            author:
              type: object
              properties:
                user_id:
                  type: integer
                  example: 1
                avatar_color:
                  type: string
                  example: avatar color
                email:
                  type: string
                  example: email
                avatar_url:
                  type: string
                  example: avatar url
                display_name:
                  type: string
                  example: display name
            results:
              type: object
              properties:
                answer1:
                  type: integer
                  example: 1
                answer2:
                  type: integer
                  example: 2
            total_participants:
              type: integer
              example: 1
            config:
              type: object
              properties:
                options:
                  type: array
                  items:
                    type: string
                    example: answer1, answer2
    Feeds.Video.Resource:
      type: object
      properties:
        id:
          type: string
          description: Unique identifier for this video
          example: 456
    Feeds.Attachment.Resource:
      type: object
      properties:
        id:
          type: string
          description: Unique identifier for this attachment
          example: uuid
    Feeds.RenderedPost.Resource:
      type: object
      properties:
        id:
          type: integer
          description: Unique identifier for this post
          example: 456
        content_type:
          type: string
          description: >-
            The type of content. One of: article, image, link, note, or video.
            The content_type can determine how the post should be presented.
          example: article
        locale:
          type: string
          description: The locale. For non-translatable posts, this value will be null.
          example: en
        is_translatable:
          type: boolean
          description: Whether the content is translatable.
          example: true
        rendered:
          type: string
          description: An HTML string containing the rendered content.
          example: <html><body>Rendered Content</body></html>
    Feeds.PostEngagement.Resource:
      type: object
      properties:
        id:
          type: integer
          description: Unique identifier for this post
        user_id:
          type: integer
          example: 456
        liked_at:
          type: string
          format: date-time
          description: >-
            Date and time at which the user liked the post. If the user has not
            liked the post, this value will be null.
          example: '2000-01-01T00:00:00Z'
        bookmarked_at:
          type: string
          format: date-time
          description: >-
            Date and time at which the user bookmarked the post. If the user has
            not bookmarked the post, this value will be null.
          example: '2000-01-01T00:00:00Z'
        viewed_at:
          type: string
          format: date-time
          description: >-
            Date and time at which the user viewed the post. If the user has not
            viewed the post, this value will be null.
          example: '2000-01-01T00:00:00Z'
        shares:
          type: array
          items:
            type: object
            properties:
              share_id:
                type: string
                description: The identifier of the share record used internally at Firstup.
              platform:
                type: string
                description: >-
                  The platform on which the share was created. Usually a social
                  network.
              posted_at:
                type: string
                format: date-time
                description: >-
                  The date/time at which the post was created on the external
                  platform.
              share_url:
                type: string
                description: >-
                  The url to the post where it is shared on the external
                  platform.
        total_likes_count:
          type: integer
          format: int64
          description: The total likes of this post within the program by any user.
          example: 5
        total_shares_count:
          type: integer
          format: int64
          description: The total shares of this post within the program by any user.
          example: 0
        total_bookmarks_count:
          type: integer
          format: int64
          description: >-
            The total number of bookmarks this post has got within the program
            by any user.
          example: 0
    Feed.Comment.Resource:
      type: object
      properties:
        id:
          type: integer
          description: The unique id of the comment record.
          example: 456
        uuid:
          type: string
          description: The UUID of the comment record.
          example: 8b358e6b-11d4-4e89-bf7f-ec670e3398ed
        author:
          $ref: '#/components/schemas/Content.Post.Resource.author'
        raw_body:
          type: string
          description: The body of the comment, as it was written by the user.
          example: Example comment text
        body:
          type: string
          description: The body of the comment, in HTML format.
          example: <p>Example comment text</p>
        liked:
          type: boolean
          description: Whether this comment was liked by the feed owner.
          example: true
        like_count:
          type: integer
          description: How many users have liked this comment.
          example: 5
        reply_count:
          type: integer
          description: The number of replies associated with this comment.
          example: 5
        created_at:
          type: string
          format: date-time
          description: |
            When this comment was created in ISO8601 format and UTC timezone.
          example: '2000-01-01T00:00:00Z'
        updated_at:
          type: string
          format: date-time
          description: >
            When this comment was last updated in ISO8601 format and UTC
            timezone.
          example: '2000-01-01T00:00:00Z'
        post_number:
          type: integer
          description: The identifier of the comment post.
          example: 1
    Content.Channel.Post.Resource:
      type: object
      properties:
        name:
          type: string
          example: Company News
          description: The topic name.
        description:
          type: string
          example: All the latest from our company.
          description: The topic description.
        state:
          type: string
          description: 'The state of the topic. One of: archived, hidden, or published.'
          enum:
            - active
            - published
            - hidden
            - available
            - archived
          example: published
        auto_publish:
          type: boolean
          example: true
          description: Whether the topic is set to auto-publish.
        auto_follow:
          type: boolean
          example: true
          description: Whether the topic is set to auto-follow.
        recommended:
          type: boolean
          example: true
          description: Whether the topic is recommended.
        targeted:
          type: boolean
          example: true
          description: Whether the topic is targeted.
        user_submittable:
          type: boolean
          example: true
          description: Whether the topic is user-submittable.
        groups:
          type: array
          example:
            - group1
            - group2
          description: A list of the audiences this topic is targeted to.
          items:
            type: string
        contributor_count:
          type: integer
          example: 12
          description: How many contributors this topic has.
          readOnly: true
        contributors:
          type: array
          example:
            - 1
            - 2
          description: Contributor IDs
          items:
            type: integer
        follower_count:
          type: integer
          example: 1000
          description: How many followers this topic has.
          readOnly: true
        created_at:
          type: string
          format: date-time
          description: |
            When this topic was created in ISO8601 format and UTC timezone.
          example: '2000-01-01T00:00:00Z'
          readOnly: true
        updated_at:
          type: string
          format: date-time
          description: |
            When this topic was last updated in ISO8601 format and UTC timezone.
          example: '2000-01-01T00:00:00Z'
          readOnly: true
        promoted:
          type: boolean
          description: |
            Is channel promoted
          example: true
      required:
        - name
        - description
    Content.Channel.Resource:
      allOf:
        - $ref: '#/components/schemas/Content.Channel.Post.Resource'
        - type: object
          properties:
            id:
              type: integer
              description: Unique identifier for the topic.
              example: 789
              readOnly: true
    Content.ChannelFollower.Resource:
      type: object
      properties:
        avatar_url:
          description: Path to an image representing the follower.
          type: string
          example: https://example.com/avatar.png
        display_name:
          description: The name to display as the follower.
          type: string
          example: Some User
        user_id:
          description: The Firstup user_id of the follower.
          type: integer
          example: 123
        full_name:
          description: Full name of the follower.
          type: string
          example: Bobby Brown
        username:
          description: Username of the follower.
          type: string
          example: BobbyBrown
        employee_id:
          description: Employee ID of the follower.
          type: string
          example: employee1
    Content.Post.Resource:
      type: object
      properties:
        id:
          type: integer
          description: Unique identifier for this post.
          example: 456
        version:
          type: integer
          description: >
            The version of the content creation studio used to generate the
            content.

            - `1` - Legacy Studio

            - `2` - Creator Studio
          enum:
            - 1
            - 2
        uuid:
          type: string
          format: uuid
          example: 8b358e6b-11d4-4e89-bf7f-ec670e3398ed
        content_type:
          type: string
          description: >
            The type of content. One of: article, image, link, note, or video.
            The content_type can determine how the post should be presented.
          example: article
        cover_image_alt:
          type: string
          description: >
            The url of the post on the Firstup platform. This property will only
            be returned for V2 content which can be viewed but not created via
            the Firstup API.
          example: Image of an elephant
        permalink_url:
          type: string
          description: The url of the post on the Firstup platform.
          example: https://onfirstup.com/acme/acmetimes/sc4#contents/456
        title:
          type: string
          description: The post title. Can also be considered the headline.
          example: Example Article Title
        summary:
          type: string
          description: Short summary of the post.
          example: Example article summary
        body:
          type: string
          description: The body of the post.
          example: Example article body
        state:
          type: string
          description: >
            The state of the post. One of: archived, draft, processing,
            processing_error, published, review or scheduled.
          example: published
        accent_color:
          type: string
          description: The color of the post, currently only applicable to notes.
          example: '#ae2225'
        featured_label:
          type: string
          description: The content's feature label
          example: Save Pandora!
        featured:
          type: boolean
          description: Whether the post is featured.
          example: false
        author:
          $ref: '#/components/schemas/Content.Post.Resource.author'
        channels:
          type: array
          description: A list of the topics this post is published to.
          items:
            type: object
            properties:
              id:
                type: integer
                example: 789
                description: Unique identifier for the topic.
              name:
                type: string
                example: Example Topic Name
        source:
          properties:
            type:
              type: string
              example: studio
            post_id:
              type: string
              description: >
                The unique identifier of the post on the source system, if it is
                republished from another platform or application.
              example: abc123
            posted_at:
              type: string
              description: >
                The timestamp at which the post was published on the source
                system, if it is republished from another platform or
                application.
              example: '2000-01-01T00:00:00Z'
        template:
          properties:
            id:
              type: integer
              example: 234
        visibility:
          type: string
          enum:
            - private
            - public
            - any
          description: >
            An indication of the native availability of the post within the
            Firstup platform. If 'public', the post has a public_link_url and
            shares of the post should use that url as the canonical url. If
            'private', the post requires user authentication to view.
          example: public
        shareable_url:
          type: string
          description: >
            The publicly shareable url of the post if its visibility is public.
            Private visibility posts will have no shareable_url.
          example: https://onfirstup.com/acme/acmetimes/sc4#contents/456
        language:
          type: string
          description: The language. For non-translatable posts, this value will be null.
          example: en
        is_translatable:
          type: boolean
          description: Whether the content is translatable.
          example: true
        is_commentable:
          type: boolean
          description: Whether the content allows comments.
          example: true
        comment_count:
          type: integer
          description: The number of comments on the content.
          example: 5
        created_at:
          type: string
          format: date-time
          description: |
            When this content was created in ISO8601 format and UTC timezone.
          example: '2000-01-01T00:00:00Z'
        updated_at:
          type: string
          format: date-time
          description: >
            When this content was last updated in ISO8601 format and UTC
            timezone.
          example: '2000-01-01T00:00:00Z'
        published_at:
          type: string
          format: date-time
          description: |
            When this content was published in ISO8601 format and UTC timezone.
          example: '2000-01-01T00:00:00Z'
        links:
          type: array
          items:
            type: object
            properties:
              link_url:
                type: string
                example: https://google.com
        images:
          type: array
          items:
            $ref: '#/components/schemas/Content.Image.Resource'
        image_blocks:
          type: array
          description: All image blocks of Creator Studio content
          items:
            $ref: '#/components/schemas/Content.ImageBlock.Resource'
        videos:
          type: array
          items:
            $ref: '#/components/schemas/Content.Video.Resource'
        initiatives:
          type: array
          description: A list of the initiatives.
          items:
            type: object
            properties:
              id:
                type: integer
                example: 2
                description: Unique identifier for the initiative.
              name:
                type: string
                example: Example Initiative Name
    Content.Post.Resource.author:
      type: object
      properties:
        avatar_url:
          description: Path to an image representing the author.
          type: string
          example: https://example.com/avatar.png
        display_name:
          description: The name to display as the author.
          type: string
          example: Some User
        user_id:
          description: The Firstup user_id of the author.
          type: integer
          example: 123
    Content.Comment.Resource:
      type: object
      properties:
        id:
          type: integer
          description: The unique ID of the comment record.
          example: 567
        uuid:
          type: string
          description: The UUID of the comment record.
          example: 8b358e6b-11d4-4e89-bf7f-ec670e3398ed
        author:
          $ref: '#/components/schemas/Content.Post.Resource.author'
        body:
          type: string
          description: The body of the comment, in HTML format.
          example: <p>Example comment text</p>
        raw_body:
          type: string
          description: The body of the comment as it was written by the user.
          example: Example comment text
        like_count:
          type: integer
          description: How many users have liked this comment.
          example: 5
        reply_count:
          type: integer
          description: The number of replies associated with this comment.
          example: 5
        created_at:
          type: string
          format: date-time
          description: |
            When this comment was created in ISO8601 format and UTC timezone.
          example: '2000-01-01T00:00:00Z'
        updated_at:
          type: string
          format: date-time
          description: >
            When this comment was last updated in ISO8601 format and UTC
            timezone.
          example: '2000-01-01T00:00:00Z'
        post_number:
          type: integer
          description: The identifier of the comment post.
          example: 1
    Content.Image.Resource:
      type: object
      properties:
        id:
          type: integer
          description: The unique identifier of this image record
          example: 678
        image_url:
          type: string
          example: https://cdn.example.com/acme/acmetimes/images/abc123
        width:
          type: integer
          description: The width of the image in pixels
          example: 1024
        height:
          type: integer
          description: The height of the image in pixels
          example: 768
    Content.ImageBlock.Resource:
      type: object
      properties:
        id:
          type: integer
          description: The unique identifier of this image block record
          example: 678
        image_url:
          type: string
          example: https://cdn.example.com/acme/acmetimes/images/abc123
        width:
          type: integer
          description: The width of the image in pixels
          example: 1024
        height:
          type: integer
          description: The height of the image in pixels
          example: 768
        alt_text:
          type: string
          description: The alt text of the image
          example: Example alt text
    Content.Video.Resource:
      properties:
        id:
          type: integer
          description: The unique identifier of this video record
        uuid:
          type: string
          format: uuid
          description: >
            The unique uuid identifier of this video record. Used in public
            urls.
          example: 205ba32a-7f12-439d-b33d-df1c611c8e9c
        caption:
          type: string
          description: A caption description of this video.
          example: Example video caption
        source:
          type: string
          enum:
            - youtube
            - vimeo
            - socialchorus
            - socialchorus_galaxy
            - office365
          example: socialchorus
        state:
          type: string
          enum:
            - completed
            - submitted
            - error
          example: completed
        duration:
          type: integer
          format: int64
          description: Length of the video in seconds
          example: 30
        preview_image_url:
          type: string
          description: >
            A url to an image that acts as a poster for the video before the
            video is loaded.
        embed_html:
          type: string
          description: >
            An HTML iframe widget that can be used to embed the video in an
            article.
          example: >
            <iframe
            href='https://onfirstup.com/acme/acmetimes/sc4#contents/456/videos/abc123'></iframe>
        link_url:
          type: string
          description: A link to the video where it can be played
          example: https://onfirstup.com/acme/acmetimes/sc4#contents/456/videos/abc123
        created_at:
          type: string
          format: date-time
          example: '2000-01-01T00:00:00Z'
    Content.Creation.Images:
      type: array
      description: >

        An ordered list of images for this content.


        Images are only validated for content of `"image"` type. There is a
        limit of ten images.


        *_Note:_* The content returned immediately after content creation or
        modification contains will not contain the final image URIs due to
        additional post-processing
      items:
        type: object
        required:
          - image_url
        properties:
          image_url:
            type: string
            example: https://image.site.com/an_image.png
    Scim.Group.Resource:
      type: object
      properties:
        id:
          type: integer
          description: |
            Group unique id
          example: 115
        displayName:
          type: string
          description: A human-readable name for the Group. REQUIRED.
          example: Group of users
        externalId:
          type: string
          description: >-
            ID from provisioning system. This is the resource ID on the client
            system, not Firstup's ID.
          example: 1234qweasd567
        description:
          type: string
          description: Description for the Group.
          example: Group of iOS users from partner domain
        members:
          type: array
          description: A list of members of the Group.
          example:
            - value: '3'
              _$ref: https://partner.socialchorus.com/scim/v2/Users/3
          items:
            type: object
            properties:
              value:
                type: string
                description: unique member identifier
                example: 1
              $ref:
                type: string
                description: reference to a member
                example: https://partner.socialchorus.com/scim/v2/Users/1
        meta:
          type: object
          properties:
            resourceType:
              type: string
              example: Group
            created:
              type: string
              description: date and time when the group was created
              example: '2022-05-13T13:32:00.598Z'
            lastModified:
              type: string
              description: date and time when the group was last updated
              example: '2022-05-13T13:32:00.598Z'
            location:
              type: string
              description: URL of the group
              example: https://partner.socialchorus.com/scim/v2/Groups/115
            next:
              type: string
              description: URL of the next page of group
              example: https://partner.socialchorus.com/scim/v2/Groups/115?page=2
    Scim.Group.AsyncResource:
      type: object
      properties:
        id:
          type: integer
          description: |
            Group unique id
          example: 115
        name:
          type: string
          description: A name for the Group, generated from the given displayName.
          example: group_of_users
        displayName:
          type: string
          description: A human-readable name for the Group.
          example: Group of users
        externalId:
          type: string
          description: >-
            ID from provisioning system. This is the resource ID on the client
            system, not Firstup's ID.
          example: 1234qweasd567
        description:
          type: string
          description: Description for the Group.
          example: Group of iOS users from partner domain
        members:
          type: array
          description: An empty array, as members will be changed later, asynchronously
          example: []
          items:
            type: object
        meta:
          type: object
          properties:
            resourceType:
              type: string
              example: Group
            created:
              type: string
              description: date and time when the group was created
              example: '2022-05-13T13:32:00.598Z'
            lastModified:
              type: string
              description: date and time when the group was last updated
              example: '2022-05-13T13:32:00.598Z'
            location:
              type: string
              description: URL of the group
              example: https://partner.socialchorus.com/scim/v2/Groups/115
            jobId:
              type: integer
              description: >-
                the ID of the asynchronus job, to be able to request a Job
                report
              example: 4567
        SocialChorus:1.0:Group:
          type: object
          example: {}
    Scim.Group.SocialChorusExtension:
      type: object
      properties:
        identifierField:
          type: string
          description: >
            Specifies which user identifier field to use to determine group
            membership.

            Allowed values are 'id', 'email' and 'userName'. Default value is
            'userName'.
          example: userName
    Scim.Group.UpdateRequestBody:
      $ref: '#/components/schemas/Scim.Group.BaseRequestBody'
    Scim.Group.CreateRequestBody:
      $ref: '#/components/schemas/Scim.Group.BaseRequestBody'
    Scim.Group.BaseRequestBody:
      type: object
      properties:
        displayName:
          type: string
          example: Group of specific users
        description:
          type: string
          example: Group of iOS users from partner domain
        SocialChorus:1.0:Group:
          $ref: '#/components/schemas/Scim.Group.SocialChorusExtension'
        externalId:
          type: string
          example: 1234qweasd567
        members:
          type: array
          description: >
            An array of objects representing user identifiers to be included
            into a group. The identifiers allowed are the user "id", "email" and
            "userName" (defaulting to "userName").
          example:
            - value: username3
            - value: username4
            - value: username33
          items:
            type: object
            properties:
              value:
                type: string
                example: username3
      required:
        - displayName
    Scim.Group.PatchRequestBody:
      type: object
      properties:
        schemas:
          type: array
          items:
            type: string
          example:
            - urn:ietf:params:scim:api:messages:2.0:PatchOp
        SocialChorus:1.0:Group:
          $ref: '#/components/schemas/Scim.Group.SocialChorusExtension'
        Operations:
          type: array
          items:
            type: object
            properties:
              op:
                type: string
                example: add
              path:
                type: string
                example: members
              value:
                type: array
                items:
                  type: object
                  example:
                    value: username3
    Scim.User.Resource:
      allOf:
        - $ref: '#/components/schemas/Scim.User.Core'
        - type: object
          properties:
            urn:SocialChorus:1.0:User:
              $ref: '#/components/schemas/Scim.User.SocialChorusExtension'
            urn:ietf:params:scim:schemas:extension:enterprise:2.0:User:
              $ref: '#/components/schemas/Scim.User.EnterpriseExtension'
    Scim.User.Core:
      type: object
      properties:
        meta:
          type: object
          properties:
            resourceType:
              type: string
              example: User
        id:
          $ref: '#/components/schemas/Scim.User.Core.id'
        userName:
          $ref: '#/components/schemas/Scim.User.Core.userName'
        programMembershipId:
          $ref: '#/components/schemas/Scim.User.Core.programMembershipId'
        externalId:
          $ref: '#/components/schemas/Scim.User.Core.externalId'
        name:
          $ref: '#/components/schemas/Scim.User.Core.name'
        displayName:
          $ref: '#/components/schemas/Scim.User.Core.displayName'
        nickName:
          $ref: '#/components/schemas/Scim.User.Core.nickName'
        roles:
          $ref: '#/components/schemas/Scim.User.Core.roles'
        emails:
          $ref: '#/components/schemas/Scim.User.Core.emails'
        photos:
          $ref: '#/components/schemas/Scim.User.Core.photos'
        phoneNumbers:
          $ref: '#/components/schemas/Scim.User.Core.phoneNumbers'
        addresses:
          $ref: '#/components/schemas/Scim.User.Core.addresses'
        title:
          $ref: '#/components/schemas/Scim.User.Core.title'
        userType:
          $ref: '#/components/schemas/Scim.User.Core.userType'
        locale:
          $ref: '#/components/schemas/Scim.User.Core.locale'
        timezone:
          $ref: '#/components/schemas/Scim.User.Core.timezone'
        preferredLanguage:
          $ref: '#/components/schemas/Scim.User.Core.preferredLanguage'
        active:
          $ref: '#/components/schemas/Scim.User.Core.active'
    Scim.User.Core.id:
      type: string
      example: '8675309'
      description: >

        An immutable string identifier for the user. This value will never
        change once a user is created.
    Scim.User.Core.roleString:
      type: string
      default: member
      example: publisher
      enum:
        - administrator
        - program_manager
        - analyst
        - publisher
        - channel_contributor
        - member
    Scim.User.Core.roleObject:
      description: >
        The roles key is an array containing a single object that defines the
        user's

        role or legacy role within the Firstup application. This key provides
        crucial

        information about the user's permissions and access level, allowing for

        precise role-based management and authorization across the platform.
      type: object
      properties:
        type:
          type: string
          description: >
            The `type` field specifies the role or access permissions in the
            Firstup API. It encompasses the following key elements:

            The `type` field specifies the role or access permissions in the
            Firstup API.

            It encompasses the following key elements:


            - **Role:** Represents the Creator Studio Advanced Permissions Role,
            defining the user's overarching responsibilities.

            - **Scope:** Indicates the restrictions associated with the Advanced
            Permissions Role, determining the records the user can access within
            Firstup.

            - **Legacy Roles:** Deprecated roles from the past that may still be
            associated with the user. In most scenarios, these roles are no
            longer utilized and are not required for current functionality.


            Ensure to review and align roles and scopes for effective management
            of user access and permissions.
          enum:
            - role
            - scope
            - legacy_role
        value:
          type: string
          description: >
            The `value` field within the context of the Firstup API represents
            the identifier or key associated with the corresponding record.

            This identifier links to the specific record defined by the user's
            role, scope, or legacy roles.


            For example, if the `type` is role, the `value` would point to the
            unique identifier for that role.
          nullable: true
          example:
            - type: role
              value: brand_admin
            - type: scope
              value: audience:15
            - type: scope
              value: topic:26
            - type: legacy_role
              value: program_manager
    Scim.User.Core.rolesObjectArray:
      type: array
      minItems: 1
      example:
        - member
      items:
        oneOf:
          - $ref: '#/components/schemas/Scim.User.Core.roleString'
          - $ref: '#/components/schemas/Scim.User.Core.roleObject'
    Scim.User.Core.userName:
      type: string
      example: janeDoe123
      description: >
        `userName` uniquely identifies a user in the scope of your organization.
        It can be updated by the client, but must remain unique.


        In Firstup Studio it is referred to as `federated_identifier`.
    Scim.User.Core.programMembershipId:
      type: string
      example: '262574'
      description: |
        An immutable string identifier for the user's program membership.
    Scim.User.Core.externalId:
      example: ext_123489
      description: >-
        ID from provisioning system. This is the resource ID on the client
        system, not Firstup's ID.
      oneOf:
        - type: string
          nullable: true
        - type: integer
          nullable: true
    Scim.User.Core.name:
      type: object
      properties:
        givenName:
          type: string
          example: Jane
          description: User's first name
        familyName:
          type: string
          example: Doe
          description: User's last name
      description: |
        An object containing multiple parts that make up a user's name.
      required:
        - givenName
        - familyName
      additionalProperties: false
    Scim.User.Core.displayName:
      type: string
      nullable: true
      description: |
        <div class="warning-box">
          Please refrain from using this attribute without prior consultation with our support staff.
        </div>
        <p>
          This attribute serves a distinct purpose within the Firstup system, requires a specific format
          and inappropriate use may introduce unintended side effects.
        </p>
    Scim.User.Core.nickName:
      type: string
      nullable: true
      example: Jane
      description: The casual way to address the user in real life.
    Scim.User.Core.active:
      example: true
      description: |

        Whether or not the user is currently marked "active" in the program.
      oneOf:
        - type: boolean
        - type: string
    Scim.User.Core.roles:
      description: >
        Defines a user's permissions and access privileges within a system or
        application.


        The provided array extends support for Advanced Permissions, while
        supporting legacy Roles from Classic Studio. It accommodates a list of
        objects, each detailing the user's role, record permissions (scope), and
        legacy role if applicable.


        **Discover Available Roles**


        To explore available roles, make use of the **GET** request at
        `/scim/v2/roles`.


        **Available Legacy Roles**

        - administrator

        - program_manager

        - analyst

        - publisher

        - channel_contributor

        - member


        **Additional Resources**


        For comprehensive insights into roles, scopes, and legacy roles refer to
        the following Knowledge Base Articles:


        -
        [Roles-Standard](https://support.firstup.io/hc/en-us/articles/6278321908503)

        -
        [Roles-Custom](https://support.firstup.io/hc/en-us/articles/6744088254359)

        - [Scopes or
        Restrictions](https://support.firstup.io/hc/en-us/articles/6278321908503#h_01HBV399TW5WN1ZZABQF845H4E)

        - [Legacy
        Roles](https://howto.socialchorus.com/hc/en-us/articles/115006356588#h_23542235341518566935216)


        **Backward Compatibility:**

        - Support the original single-string legacy role format
        ["`legacy_role`"]

        - Legacy roles include "administrator",  "program_manager", "analyst",
        "publisher", "channel_contributor", or "member".

        - GET /scim/v2/users and /scim/v2/users/{user_id} return this field
        based on a program configuration. Please contact

        <support@firstup.io> if you need to switch the syntax.


        Note: Firstup users have a single role and legacy_role but can have
        multiple scopes applied.


        ---


        > ### Limitation Notice: Scope

        > In addition to role and legacy_role the array supports the setting of
        record restrictions via scope objects. This includes the ability to
        define Topic, Audience, Template, and Email Aliases Permissions.

        >

        > **Issue:**

        > Currently the API does not validate the scope data against existing
        restriction records. While this does not compromise system security, it
        may result in users experiencing unexpected access limitations.

        >

        > **Impact:**

        > Users will still be able to access the application, but their access
        may not align with expectations due to permissions for records that are
        not valid. It's crucial to recognize that topic, audience, template, and
        email scopes play a pivotal role in limiting users to only seeing
        records defined within those specified scopes.

        >

        > **Recommendation:**

        > To ensure accurate access and visibility, we recommend using the Bulk
        Permissions UI. This ensures that restrictions align with the intended
        access for users, providing a proactive approach to managing and
        validating restriction data effectively.


        ---
      oneOf:
        - $ref: '#/components/schemas/Scim.User.Core.roleString'
        - $ref: '#/components/schemas/Scim.User.Core.rolesObjectArray'
    Scim.User.Core.emails:
      type: array
      description: |
        A list of the user's emails.
        If a user has no emails this will be an empty list.
      items:
        $ref: '#/components/schemas/Scim.User.Core.email'
    Scim.User.Core.photos:
      type: array
      description: |
        A list containing at most a single element, the user's avatar photo URL.
        If a user has no avatar photo URL this will be an empty list.
      items:
        $ref: '#/components/schemas/Scim.User.Core.photo'
    Scim.User.Core.phoneNumbers.create:
      type: array
      description: |

        A list of the user's phone numbers.

        If a user has no phone numbers this will be an empty list.

        <div class="info-box">
          <p>
            <strong>Note:</strong> The SCIM spec allows an arbitrary number
            of phone numbers with arbitrary types, but Firstup will only save
            numbers of types <code>"main"</code> and <code>"mobile"</code>,
            and only a single number for each type.
          </p>


          <p>
            It is not an <em>error</em> to include other types or additional
            numbers, but they will be ignored without an error message.
          </p>
        </div>
      items:
        $ref: '#/components/schemas/Scim.User.Core.phoneNumber'
    Scim.User.Core.phoneNumbers:
      type: array
      description: >

        A list of the user's phone numbers.


        If a user has no phone numbers this will be an empty list.


        Firstup only saves and returns phone numbers with a `type` of `main` and
        `mobile`.
      items:
        $ref: '#/components/schemas/Scim.User.Core.phoneNumber'
    Scim.User.Core.email:
      type: object
      additionalProperties: false
      properties:
        value:
          type: string
          example: janedoe@email.com
          description: A valid email address
        primary:
          type: boolean
          example: true
          description: Indicates if the value is the user's primary email address
        type:
          example: work
          enum:
            - work
            - home
            - other
            - null
          description: An email type. Should be one of "work", "home", "other" or null
          nullable: true
          type: string
    Scim.User.Core.photo:
      type: object
      additionalProperties: false
      properties:
        value:
          type: string
          example: http://some.url/photo.png
          description: Direct link to photo image resource
        type:
          type: string
          example: photo
          enum:
            - photo
          description: The type of photo; only "photo" is supported.
    Scim.User.Core.phoneNumber:
      type: object
      additionalProperties: false
      properties:
        value:
          type: string
          example: 555-1212
          description: A phone number
        type:
          type: string
          example: mobile
          enum:
            - main
            - mobile
            - work
          description: >

            The type of phone number. Only `"main"` and `"mobile"` are saved or
            returned by Firstup.

              DO NOT use `work` as the phone number type because it will be ignored. It's listed for third-party compatibility only.
        primary:
          type: boolean
          example: true
          description: >-
            This optional attribute is for compatibility purposes only and is
            ignored by Firstup.
    Scim.User.Core.addresses:
      type: array
      description: >

        The user's addresses in the program.

        A Firstup user has only one address. The user's address will be set to
        either:

        * The first address, or... * The first address marked `primary`.

        Sending anything other than an array (which may be empty) is an error.
      items:
        type: object
        additionalProperties: false
        properties:
          streetAddress:
            type: string
            nullable: true
            example: 123 Mission St
            description: A street address, e.g., house number and street name.
          locality:
            type: string
            nullable: true
            example: San Francisco
            description: Address's locality, e.g, in the US, the city.
          region:
            type: string
            nullable: true
            example: CA
            description: Address's region, e.g., in the US, the state.
          postalCode:
            type: string
            nullable: true
            example: '94105'
            description: Address's postal code, e.g., in the US, the zip code.
          country:
            type: string
            nullable: true
            example: US
            description: Address's country.
          primary:
            type: boolean
            example: false
            description: Is address primary
          formatted:
            type: string
            nullable: true
            example: 123 Mission St, San Francisco, CA, 94105
            description: Complete address as formatted string.
          type:
            type: string
            nullable: true
            example: work
            description: Address type. This field is ignored by Firstup.
    Scim.User.Core.photos.incoming:
      type: array
      description: |

        The user's photo (avatar).

        * Firstup users have a single avatar photo.
        * The single photo must be contained within an array.
        * Sending multiple photos is ok but only the first photo is used.
        * Only the first photo is validated for correctness.
      items:
        type: object
        properties:
          type:
            type: string
            example: photo
            description: |

              The type of photo.

              Only `"photo"` is supported&mdash;any other value is an error.
          value:
            type: string
            example: http://an.image/url
            description: >

              The URI of the photo (avatar).


              URIs may be HTTP, HTTPS, or DATA. DATA URIs must contain a
              complete data URI including the MIME type, encoding, and data,
              e.g., `data:image/jpeg;base64,/9j/4AAQSkZJRgABAQAAAQABAAD...`


              All photos are downloaded by Firstup and self-hosted: the
              resulting photo URL will not be the same as the incoming URI.
    Scim.User.Core.title:
      type: string
      description: A string containing the user's job title.
      example: Vice President
    Scim.User.Core.userType:
      type: string
      description: The user's employee type
      example: Associate
    Scim.User.Core.locale:
      type: string
      description: The user's locale.
      example: en-US
    Scim.User.Core.timezone:
      type: string
      description: The user's timezone.
      example: US/Chicago
    Scim.User.Core.preferredLanguage:
      type: string
      description: A string containing the user's preferred language.
      example: en-US
    Scim.User.SocialChorusExtension:
      type: object
      additionalProperties: false
      properties:
        businessUnit:
          type: string
          nullable: true
          description: The user's business unit.
          example: Accounts Receivable
        gender:
          type: string
          nullable: true
          description: The user's gender.
          example: Female
        managerName:
          type: string
          nullable: true
          description: The user's manager's name.
          example: Jimmy Dean
        workLocation:
          type: string
          nullable: true
          description: The user's work location.
          example: Kabukicho
        birthDate:
          type: string
          nullable: true
          format: date-time
          description: The user's birth date.
          example: '2000-01-01T00:00:00.000Z'
        hireDate:
          type: string
          nullable: true
          format: date-time
          description: The user's start of employment date.
          example: '2000-01-01T00:00:00.000Z'
        promotionDate:
          type: string
          nullable: true
          format: date-time
          description: The user's promotion date.
          example: '2000-01-01T00:00:00.000Z'
        requisitionApprovalDate:
          type: string
          nullable: true
          format: date-time
          description: The Requisition Approval date.
          example: '2000-01-01T00:00:00.000Z'
        lastAccessedAt:
          type: string
          nullable: true
          format: date-time
          description: Please contact your Firstup representative for more information.
          example: '2000-01-01T00:00:00.000Z'
        customAttributes:
          type: array
          description: >
            An array of objects including a name and value. These are stored as
            an arbitrary additional list of attributes associated to the user
            and can be used to create Groups and audiences in the Firstup
            platform. Currently, Custom Attributes can only be string values.
          example:
            - name: favorite_food
              value: pizza
            - name: favorite_sport
              value: soccer
            - name: hair_color
              value: brown
          items:
            oneOf:
              - type: object
                properties:
                  name:
                    type: string
                    description: The name of the attribute
                  value:
                    type: string
                    nullable: true
                    description: The value of the attribute
                required:
                  - name
                  - value
                additionalProperties: false
              - allOf:
                  - not:
                      required:
                        - name
                        - value
                  - type: object
                    additionalProperties:
                      type: string
                    minProperties: 1
    Scim.User.EnterpriseExtension:
      type: object
      additionalProperties: false
      properties:
        employeeNumber:
          type: string
          nullable: true
          example: abc123
          description: An employee id or identifier used in external systems.
        organization:
          type: string
          nullable: true
          example: Firstup
          description: The employee organization name
        department:
          type: string
          nullable: true
          example: HR
          description: The employee's department name
        costCenter:
          type: string
          nullable: true
          description: The user's cost center
          example: NY
        division:
          type: string
          nullable: true
          description: The user's division
          example: THCI
    Scim.User.UpdateRequestBody:
      type: object
      properties:
        userName:
          $ref: '#/components/schemas/Scim.User.Core.userName'
        active:
          type: boolean
          description: Whether the user is active or blocked in the program.
          example: true
        name:
          $ref: '#/components/schemas/Scim.User.Core.name'
        displayName:
          $ref: '#/components/schemas/Scim.User.Core.displayName'
        nickName:
          $ref: '#/components/schemas/Scim.User.Core.nickName'
        roles:
          $ref: '#/components/schemas/Scim.User.Core.roles'
        emails:
          $ref: '#/components/schemas/Scim.User.Core.emails'
        addresses:
          $ref: '#/components/schemas/Scim.User.Core.addresses'
        title:
          $ref: '#/components/schemas/Scim.User.Core.title'
        photos:
          $ref: '#/components/schemas/Scim.User.Core.photos.incoming'
        preferredLanguage:
          $ref: '#/components/schemas/Scim.User.Core.preferredLanguage'
        userType:
          $ref: '#/components/schemas/Scim.User.Core.userType'
        locale:
          $ref: '#/components/schemas/Scim.User.Core.locale'
        timezone:
          $ref: '#/components/schemas/Scim.User.Core.timezone'
        urn:SocialChorus:1.0:User:
          $ref: '#/components/schemas/Scim.User.SocialChorusExtension'
        urn:ietf:params:scim:schemas:extension:enterprise:2.0:User:
          $ref: '#/components/schemas/Scim.User.EnterpriseExtension'
    Scim.User.CreateRequestBody:
      type: object
      properties:
        schemas:
          type: array
          items:
            type: string
            enum:
              - urn:ietf:params:scim:schemas:core:2.0:User
              - urn:ietf:params:scim:schemas:extension:enterprise:2.0:User
              - urn:SocialChorus:1.0:User
          example:
            - urn:ietf:params:scim:schemas:core:2.0:User
        userName:
          $ref: '#/components/schemas/Scim.User.Core.userName'
        name:
          $ref: '#/components/schemas/Scim.User.Core.name'
        displayName:
          $ref: '#/components/schemas/Scim.User.Core.displayName'
        externalId:
          $ref: '#/components/schemas/Scim.User.Core.externalId'
        nickName:
          $ref: '#/components/schemas/Scim.User.Core.nickName'
        active:
          $ref: '#/components/schemas/Scim.User.Core.active'
        roles:
          $ref: '#/components/schemas/Scim.User.Core.roles'
        phoneNumbers:
          $ref: '#/components/schemas/Scim.User.Core.phoneNumbers.create'
        emails:
          $ref: '#/components/schemas/Scim.User.Core.emails'
        addresses:
          $ref: '#/components/schemas/Scim.User.Core.addresses'
        title:
          $ref: '#/components/schemas/Scim.User.Core.title'
        photos:
          $ref: '#/components/schemas/Scim.User.Core.photos.incoming'
        preferredLanguage:
          $ref: '#/components/schemas/Scim.User.Core.preferredLanguage'
        userType:
          $ref: '#/components/schemas/Scim.User.Core.userType'
        locale:
          $ref: '#/components/schemas/Scim.User.Core.locale'
        timezone:
          $ref: '#/components/schemas/Scim.User.Core.timezone'
        urn:SocialChorus:1.0:User:
          $ref: '#/components/schemas/Scim.User.SocialChorusExtension'
        urn:ietf:params:scim:schemas:extension:enterprise:2.0:User:
          $ref: '#/components/schemas/Scim.User.EnterpriseExtension'
      required:
        - userName
    Scim.User.PatchRequestBody:
      type: object
      properties:
        schemas:
          type: array
          items:
            type: string
          example:
            - urn:ietf:params:scim:api:messages:2.0:PatchOp
        Operations:
          type: array
          items:
            type: object
            properties:
              op:
                type: string
                example: replace
              path:
                type: string
                example: active
              value:
                type: object
                example: false
          example:
            - op: replace
              path: active
              value: false
            - op: replace
              path: emails[type eq "work"].value
              value: janedoe@email.com
    Scim.Role.Resource:
      type: object
      properties:
        value:
          type: string
          description: |
            The value of a role (name)
          example: group_admin
        display:
          type: string
          description: A human-readable name, primarily used for display purposes.
          example: Community Admin
        type:
          type: string
          description: A label indicating the role's function.
          example: primary
        enabled:
          type: boolean
          description: >-
            A boolean type that indicates if the role is enabled and usable in
            the SCIM service provider's system.
          example: true
        contains:
          type: array
          description: >-
            A complex type that shows what other roles this role indirectly
            grants - values can be considered the child role in a parent/child
            relationship.
          example:
            - moderate_comments
            - create_audience
            - publish_campaign
            - insights
          items:
            type: string
            example: publish_campaign
    Webhooks.Subscription.Resource:
      type: object
      properties:
        id:
          $ref: '#/components/schemas/Webhooks.Subscription.id'
        url:
          $ref: '#/components/schemas/Webhooks.Subscription.url'
        authorization_header:
          $ref: '#/components/schemas/Webhooks.Subscription.authorization_header'
        active:
          $ref: '#/components/schemas/Webhooks.Subscription.active'
        events:
          type: array
          items:
            $ref: '#/components/schemas/Webhooks.Subscription.Event'
        created_at:
          type: string
          format: date-time
          example: '2000-01-01T00:00:00Z'
        updated_at:
          type: string
          format: date-time
          example: '2000-01-01T00:00:00Z'
    Webhooks.Subscription.Event:
      type: object
      properties:
        name:
          description: The name of the event.
          example: content_published
        version:
          description: The version of the event this subscription uses.
          example: '1'
    Webhooks.Subscription.Ping:
      type: object
      properties:
        delivery:
          $ref: '#/components/schemas/Webhooks.Delivery.Resource'
        subscription:
          type: object
          properties:
            id:
              $ref: '#/components/schemas/Webhooks.Subscription.id'
            url:
              $ref: '#/components/schemas/Webhooks.Subscription.url'
    Webhooks.Delivery.Resource:
      type: object
      properties:
        id:
          $ref: '#/components/schemas/Webhooks.Delivery.id'
        status:
          $ref: '#/components/schemas/Webhooks.Delivery.status'
    Webhooks.Subscription.id:
      type: string
      description: Unique identifier for this subscription.
      example: abc123
    Webhooks.Subscription.url:
      type: string
      format: url
      description: >-
        The url that will be called when delivering events for this
        subscription.
      example: https://example.com/webhook
    Webhooks.Subscription.authorization_header:
      type: string
      description: >-
        A value will be sent in every delivery as the 'Authorization' header
        value in the POST request.
      example: Bearer abc123-some-token
    Webhooks.Subscription.active:
      type: boolean
      description: >-
        Whether the subscription is "turned on". Inactive subscriptions will not
        send deliveries to the subscription url except for ping deliveries.
      example: true
    Webhooks.Subscription.CreateRequestBody:
      type: object
      properties:
        url:
          $ref: '#/components/schemas/Webhooks.Subscription.url'
        authorization_header:
          $ref: '#/components/schemas/Webhooks.Subscription.authorization_header'
        active:
          $ref: '#/components/schemas/Webhooks.Subscription.active'
        events:
          type: array
          items:
            $ref: '#/components/schemas/Webhooks.Subscription.Event'
    Webhooks.Subscription.UpdateRequestBody:
      type: object
      properties:
        url:
          $ref: '#/components/schemas/Webhooks.Subscription.url'
        authorization_header:
          $ref: '#/components/schemas/Webhooks.Subscription.authorization_header'
        active:
          $ref: '#/components/schemas/Webhooks.Subscription.active'
        events:
          type: array
          items:
            $ref: '#/components/schemas/Webhooks.Subscription.Event'
    Webhooks.Delivery.id:
      type: string
      description: >
        The unique id of the delivery. This value is also provided in the
        'X-SocialChorus-Delivery' header of the request made to the
        subscription's url.
      example: abc123-456
    Webhooks.Delivery.status:
      type: string
      enum:
        - pending
        - success
        - failure
        - retryable
      description: >
        A value indicating the status of the delivery and the response we
        received back when sending the delivery to the subscription's url.
      example: success
    Assistant.Inbox.Items.Resource:
      type: array
      items:
        type: object
        properties:
          id:
            type: integer
            example: 1
          categories:
            type: string
            example: categories
          resource_type:
            type: string
            example: resource_type
          resource_url:
            type: string
            example: resource_url
          text:
            type: string
            example: text
          image_icon:
            type: object
            properties:
              url:
                type: string
                example: url
          attribution:
            type: string
            example: text
    Assistant.Inbox.Todos.Resource:
      type: array
      items:
        type: object
        properties:
          id:
            type: integer
            example: 1
          category:
            type: string
            example: category
          label:
            type: string
            example: label
          created_at:
            type: string
            format: date-time
          updated_at:
            type: string
            format: date-time
          resource:
            type: object
            properties:
              id:
                type: integer
                example: 1
              url:
                type: string
                example: url
          actions:
            type: array
            items:
              type: object
              properties:
                name:
                  type: string
                  example: name
                label:
                  type: string
                  example: label
                method:
                  type: string
                  example: method
                url:
                  type: string
                  example: url
    Assistant.Inbox.Notifications.Resource:
      type: array
      items:
        type: object
        properties:
          id:
            type: integer
            example: 1
          category:
            type: string
            example: category_type
          acknowledged:
            type: boolean
            example: false
          text:
            type: string
            example: text
          label:
            type: string
            example: Label name
          details:
            type: object
            properties:
              url:
                type: string
                example: url
          created_at:
            type: string
            example: '2022-07-06T07:15:46.121Z'
          updated_at:
            type: string
            example: '2022-07-06T07:15:46.121Z'
    Standard.Meta.CursorPagination:
      type: object
      properties:
        cursor:
          description: The cursor value used for the set of records returned.
          example: current-cursor-value
        next:
          description: >
            The cursor value that can be used for the _next_ set of records in
            the next request using the same filters.
          example: nex-cursor-value
        page_size:
          description: >
            The max number of records requested with pagination applied. Is not
            necessarily an exact count of the current records returned.
          default: 10
          example: 10
    Standard.Meta.PagePagination:
      type: object
      properties:
        page:
          description: The page returned.
          default: 1
          example: 1
        page_size:
          description: >
            The max number of records requested with pagination applied. Is not
            necessarily an exact count of the current records returned.
          default: 10
          example: 10
        total_records:
          description: >
            A count of all records if the request were not paginated. If filters
            are applied, total_records only counts records matching the filters.
          example: 20
    Standard.Feed.Meta.PagePagination:
      type: object
      properties:
        page:
          description: The page returned.
          default: 1
          example: 1
        page_size:
          description: >
            The max number of records requested with pagination applied. Is not
            necessarily an exact count of the current records returned.
          default: 10
          example: 10
