360Learning Certificate Outlines API

The Certificate Outlines API from 360Learning โ€” 2 operation(s) for certificate outlines.

OpenAPI Specification

360learning-certificate-outlines-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: Bulk Authentication Certificate Outlines API
  description: ''
  version: 1.0.0
  contact: {}
servers:
- url: https://app.360learning.com
  description: Production EU
- url: https://app.us.360learning.com
  description: Production US
tags:
- name: Certificate Outlines
paths:
  /api/v2/certificate-outlines:
    post:
      description: '> ๐Ÿ”‘

        >

        > Required OAuth scope: `certificateOutlines:write`.


        Creates a new certificate outline in your platform.'
      operationId: v2.certificateOutlines.CreateCertificateOutlineController_createCertificateOutline
      parameters:
      - name: 360-api-version
        in: header
        description: The version of the API.
        required: true
        schema:
          type: string
          enum:
          - v2.0
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/InputCertificateOutlineDTO'
      responses:
        '200':
          description: Returns newly created certificate outline.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CertificateOutlineResponseDTO'
        '400':
          description: The server cannot or will not process the request due to something that is perceived to be a client error.
          content:
            application/json:
              schema:
                oneOf:
                - description: A tag is mandatory for the given wording.
                  title: Wording With Missing Tag
                  type: object
                  properties:
                    error:
                      type: object
                      properties:
                        code:
                          type: string
                          enum:
                          - wordingWithMissingTag
                        message:
                          type: string
                          example: A human-readable message to help with debugging.
                      required:
                      - code
                      - message
                  required:
                  - error
                - description: The given media ID does not correspond to any existing image media.
                  title: Media Not Found
                  type: object
                  properties:
                    error:
                      type: object
                      properties:
                        code:
                          type: string
                          enum:
                          - mediaNotFound
                        message:
                          type: string
                          example: A human-readable message to help with debugging.
                      required:
                      - code
                      - message
                  required:
                  - error
        '401':
          description: The given access token is either missing, invalid, has expired, or has been revoked.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    enum:
                    - invalid_token
                required:
                - error
        '403':
          description: The given access token does not have the required OAuth scope to execute the request.
          content:
            application/json:
              schema:
                title: Invalid Scope
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        enum:
                        - invalid_scope
                      message:
                        type: string
                        example: A human-readable message to help with debugging.
                    required:
                    - code
                    - message
                required:
                - error
        '404':
          description: The given `groupId` does not correspond to any existing group.
          content:
            application/json:
              schema:
                title: Group Not Found
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        enum:
                        - groupNotFound
                      message:
                        type: string
                        example: A human-readable message to help with debugging.
                    required:
                    - code
                    - message
                required:
                - error
        '429':
          description: 'The client has sent too many requests in a short amount of time. '
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    enum:
                    - tooManyRequests
                required:
                - error
      security:
      - oauth2: []
      summary: Create certificate outline
      tags:
      - Certificate Outlines
    get:
      description: '> ๐Ÿ”‘

        >

        > Required OAuth scope: `certificateOutlines:read`.


        Lists all certificate outlines in your platform.'
      operationId: v2.certificateOutlines.GetCertificateOutlinesController_getCertificateOutlines
      parameters:
      - name: 360-api-version
        in: header
        description: The version of the API.
        required: true
        schema:
          type: string
          enum:
          - v2.0
      - name: createdAt
        required: false
        in: query
        style: deepObject
        explode: true
        description: 'Filter on **createdAt** property with LHS bracket notation.


          Expected value format is a date (YYYY-MM-DDThh:mm:ss.sssZ). The milliseconds are always set to 0.'
        schema:
          properties:
            lt:
              type: string
              format: date-time
              description: Filter on dates lower than the given one
              example: '2020-01-01T10:30:26.000Z'
            gte:
              type: string
              format: date-time
              description: Filter on dates greater than or equal the given one
              example: '2020-01-01T10:30:26.000Z'
      - name: groupId
        required: false
        in: query
        style: deepObject
        explode: true
        description: 'Filter on **groupId** property with LHS bracket notation.


          Expected value format is a valid ID (24 digits or letters).'
        schema:
          properties:
            eq:
              type: string
              format: ObjectId
              pattern: ^[a-fA-F0-9]{24}$
              description: Filter on values equal to the given one
              example: 507f1f77bcf86cd799439011
            ne:
              type: string
              format: ObjectId
              pattern: ^[a-fA-F0-9]{24}$
              description: Filter on values not equal to the given one
              example: 507f1f77bcf86cd799439011
            in:
              type: array
              description: Filter on values including the given ones
              items:
                type: string
                format: ObjectId
                pattern: ^[a-fA-F0-9]{24}$
                example: 507f1f77bcf86cd799439011
            nin:
              type: array
              description: Filter on values excluding the given ones
              items:
                type: string
                format: ObjectId
                pattern: ^[a-fA-F0-9]{24}$
                example: 507f1f77bcf86cd799439011
      responses:
        '200':
          description: Returns all certificate outlines in the company.
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/CertificateOutlineResponseDTO'
        '401':
          description: The given access token is either missing, invalid, has expired, or has been revoked.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    enum:
                    - invalid_token
                required:
                - error
        '403':
          description: The given access token does not have the required OAuth scope to execute the request.
          content:
            application/json:
              schema:
                title: Invalid Scope
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        enum:
                        - invalid_scope
                      message:
                        type: string
                        example: A human-readable message to help with debugging.
                    required:
                    - code
                    - message
                required:
                - error
        '429':
          description: 'The client has sent too many requests in a short amount of time. '
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    enum:
                    - tooManyRequests
                required:
                - error
      security:
      - oauth2: []
      summary: List all certificate outlines
      tags:
      - Certificate Outlines
  /api/v2/certificate-outlines/{certificateOutlineId}:
    delete:
      description: '> ๐Ÿ”‘

        >

        > Required OAuth scope: `certificateOutlines:write`.


        Deletes a specific certificate outline given its unique ID.'
      operationId: v2.certificateOutlines.DeleteCertificateOutlineController_deleteCertificateOutline
      parameters:
      - name: 360-api-version
        in: header
        description: The version of the API.
        required: true
        schema:
          type: string
          enum:
          - v2.0
      - name: certificateOutlineId
        required: true
        in: path
        description: The unique ID of the certificate outline.
        schema:
          format: ObjectId
          pattern: ^[a-fA-F0-9]{24}$
          example: 507f1f77bcf86cd799439011
          type: string
      responses:
        '204':
          description: Deletes a specific certificate outline.
        '401':
          description: The given access token is either missing, invalid, has expired, or has been revoked.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    enum:
                    - invalid_token
                required:
                - error
        '403':
          description: The given access token does not have the required OAuth scope to execute the request.
          content:
            application/json:
              schema:
                title: Invalid Scope
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        enum:
                        - invalid_scope
                      message:
                        type: string
                        example: A human-readable message to help with debugging.
                    required:
                    - code
                    - message
                required:
                - error
        '404':
          description: The given `certificateOutlineId` does not correspond to any existing certificate outline.
          content:
            application/json:
              schema:
                title: Certificate Outline Not Found
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        enum:
                        - certificateOutlineNotFound
                      message:
                        type: string
                        example: A human-readable message to help with debugging.
                    required:
                    - code
                    - message
                required:
                - error
        '409':
          description: The given `certificateOutlineId` is used in paths.
          content:
            application/json:
              schema:
                title: Certificate Outline Still Used
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        enum:
                        - certificateOutlineStillUsed
                      message:
                        type: string
                        example: A human-readable message to help with debugging.
                    required:
                    - code
                    - message
                required:
                - error
        '429':
          description: 'The client has sent too many requests in a short amount of time. '
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    enum:
                    - tooManyRequests
                required:
                - error
      security:
      - oauth2: []
      summary: Delete a certificate outline
      tags:
      - Certificate Outlines
    patch:
      description: '> ๐Ÿ”‘

        >

        > Required OAuth scope: `certificateOutlines:write`.


        Edits specific fields of an existing certificate outline. Fields not included in the request payload remain unchanged.'
      operationId: v2.certificateOutlines.UpdateCertificateOutlineController_updateCertificateOutline
      parameters:
      - name: 360-api-version
        in: header
        description: The version of the API.
        required: true
        schema:
          type: string
          enum:
          - v2.0
      - name: certificateOutlineId
        required: true
        in: path
        description: The unique ID of the certificate outline.
        schema:
          format: ObjectId
          pattern: ^[a-fA-F0-9]{24}$
          example: 507f1f77bcf86cd799439011
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PatchCertificateOutlineDTO'
      responses:
        '200':
          description: Returns the updated certificate outline.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CertificateOutlineResponseDTO'
        '400':
          description: The server cannot or will not process the request due to something that is perceived to be a client error.
          content:
            application/json:
              schema:
                oneOf:
                - description: The given media ID does not correspond to any existing image media.
                  title: Media Not Found
                  type: object
                  properties:
                    error:
                      type: object
                      properties:
                        code:
                          type: string
                          enum:
                          - mediaNotFound
                        message:
                          type: string
                          example: A human-readable message to help with debugging.
                      required:
                      - code
                      - message
                  required:
                  - error
                - description: A tag is mandatory for the given wording.
                  title: Wording With Missing Tag
                  type: object
                  properties:
                    error:
                      type: object
                      properties:
                        code:
                          type: string
                          enum:
                          - wordingWithMissingTag
                        message:
                          type: string
                          example: A human-readable message to help with debugging.
                      required:
                      - code
                      - message
                  required:
                  - error
        '401':
          description: The given access token is either missing, invalid, has expired, or has been revoked.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    enum:
                    - invalid_token
                required:
                - error
        '403':
          description: The given access token does not have the required OAuth scope to execute the request.
          content:
            application/json:
              schema:
                title: Invalid Scope
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        enum:
                        - invalid_scope
                      message:
                        type: string
                        example: A human-readable message to help with debugging.
                    required:
                    - code
                    - message
                required:
                - error
        '404':
          description: The server cannot find the requested resource.
          content:
            application/json:
              schema:
                oneOf:
                - description: The given `certificateOutlineId` does not correspond to any existing certificate outline.
                  title: Certificate Outline Not Found
                  type: object
                  properties:
                    error:
                      type: object
                      properties:
                        code:
                          type: string
                          enum:
                          - certificateOutlineNotFound
                        message:
                          type: string
                          example: A human-readable message to help with debugging.
                      required:
                      - code
                      - message
                  required:
                  - error
                - description: The given `groupId` does not correspond to any existing group.
                  title: Group Not Found
                  type: object
                  properties:
                    error:
                      type: object
                      properties:
                        code:
                          type: string
                          enum:
                          - groupNotFound
                        message:
                          type: string
                          example: A human-readable message to help with debugging.
                      required:
                      - code
                      - message
                  required:
                  - error
        '429':
          description: 'The client has sent too many requests in a short amount of time. '
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    enum:
                    - tooManyRequests
                required:
                - error
      security:
      - oauth2: []
      summary: Edit a certificate outline
      tags:
      - Certificate Outlines
components:
  schemas:
    PatchCertificateOutlineDTO:
      title: Patch Certificate Outline
      type: object
      properties:
        title:
          type: string
          description: The title of the certificate outline.
          example: Certificate of Completion
          minLength: 1
        groupId:
          type: string
          description: The unique ID of the group this outline belongs to.
          format: ObjectId
          example: 507f1f77bcf86cd799439011
          pattern: ^[a-fA-F0-9]{24}$
        bodyHtml:
          type: string
          description: 'The content of the certificate outline. Can contain tags which will dynamically be replaced when delivering a certificate. Available tags are: [person_first_name], [person_last_name], [person_email], [person_organization], [authenticity_verification_url], [credits_acquired], [delivery_date], [path_session_title], [path_title], [reference_number], [score_reached], [start_date], [time_spent], [validity_period].'
          example: '<p>This certificate ensures [person_first_name] [person_last_name] received a certificate on [path_title] <br> This certificate was delivered by Training Organization <br> Contact: training@organization.com </p>'
          minLength: 1
        authenticityVerificationUrlWording:
          type: string
          nullable: true
          description: A wording to display the authenticity verification URL. If set, it needs to contain [authenticity_verification_url] tag.
          example: 'You can also find this document on the Internet at the following address: [authenticity_verification_url]'
        backgroundImageId:
          type: string
          nullable: true
          description: The media unique ID of the background image for this outline.
          format: ObjectId
          example: 507f1f77bcf86cd799439011
          pattern: ^[a-fA-F0-9]{24}$
        logoImageId:
          type: string
          nullable: true
          description: The media unique ID of the logo to display at the top of the certificate.
          format: ObjectId
          example: 507f1f77bcf86cd799439011
          pattern: ^[a-fA-F0-9]{24}$
        referenceNumberWording:
          type: string
          nullable: true
          description: A wording to display the reference number. If set, it needs to contain [reference_number] tag.
          example: 'Reference number: [reference_number]'
        subtitle:
          type: string
          nullable: true
          description: The subtitle of the certificate outline.
          example: Certificate topic
          minLength: 1
        validityPeriod:
          type: integer
          minimum: 1
          nullable: true
          description: Number of months of validity of the certificate.
        validityPeriodWording:
          type: string
          nullable: true
          description: A wording to display the validity period. If set, it needs to contain [validity_period] tag.
          example: This certificate is valid for a period of [validity_period] months
    InputCertificateOutlineDTO:
      title: Input Certificate Outline
      type: object
      properties:
        title:
          type: string
          description: The title of the certificate outline.
          example: Certificate of Completion
          minLength: 1
        groupId:
          type: string
          description: The unique ID of the group this outline belongs to.
          format: ObjectId
          example: 507f1f77bcf86cd799439011
          pattern: ^[a-fA-F0-9]{24}$
        bodyHtml:
          type: string
          description: 'The content of the certificate outline. Can contain tags which will dynamically be replaced when delivering a certificate. Available tags are: [person_first_name], [person_last_name], [person_email], [person_organization], [authenticity_verification_url], [credits_acquired], [delivery_date], [path_session_title], [path_title], [reference_number], [score_reached], [start_date], [time_spent], [validity_period].'
          example: '<p>This certificate ensures [person_first_name] [person_last_name] received a certificate on [path_title] <br> This certificate was delivered by Training Organization <br> Contact: training@organization.com </p>'
          minLength: 1
        authenticityVerificationUrlWording:
          type: string
          description: A wording to display the authenticity verification URL. If set, it needs to contain [authenticity_verification_url] tag.
          example: 'You can also find this document on the Internet at the following address: [authenticity_verification_url]'
        backgroundImageId:
          type: string
          description: The media unique ID of the background image for this outline.
          format: ObjectId
          example: 507f1f77bcf86cd799439011
          pattern: ^[a-fA-F0-9]{24}$
        logoImageId:
          type: string
          description: The media unique ID of the logo to display at the top of the certificate.
          format: ObjectId
          example: 507f1f77bcf86cd799439011
          pattern: ^[a-fA-F0-9]{24}$
        referenceNumberWording:
          type: string
          description: A wording to display the reference number. If set, it needs to contain [reference_number] tag.
          example: 'Reference number: [reference_number]'
        subtitle:
          type: string
          description: The subtitle of the certificate outline.
          example: Certificate topic
          minLength: 1
        validityPeriod:
          type: integer
          minimum: 1
          description: Number of months of validity of the certificate.
        validityPeriodWording:
          type: string
          description: A wording to display the validity period. If set, it needs to contain [validity_period] tag.
          example: This certificate is valid for a period of [validity_period] months
      required:
      - title
      - groupId
      - bodyHtml
    CertificateOutlineResponseDTO:
      title: Certificate Outline Response
      type: object
      properties:
        title:
          type: string
          description: The title of the certificate outline.
          example: Certificate of Completion
          minLength: 1
        groupId:
          type: string
          description: The unique ID of the group this outline belongs to.
          format: ObjectId
          example: 507f1f77bcf86cd799439011
          pattern: ^[a-fA-F0-9]{24}$
        _id:
          type: string
          description: The unique ID of the certificate outline.
          format: ObjectId
          example: 507f1f77bcf86cd799439011
          pattern: ^[a-fA-F0-9]{24}$
        createdAt:
          format: date-time
          type: string
          description: The date and time when the certificate outline was created, in the `YYYY-MM-DDThh:mm:ss.sssZ` format (ISO 8601 in Coordinated Universal Time (UTC)).
      required:
      - title
      - groupId
      - _id
      - createdAt
  securitySchemes:
    oauth2:
      type: oauth2
      flows: {}
      description: 'Use the token from the authentication endpoint in the Authorization header.


        Example: `Authorization: Bearer <token>`'