Nfon Customer Groups API

The Customer Groups API from Nfon — 8 operation(s) for customer groups.

OpenAPI Specification

nfon-customer-groups-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  description: 'The NFON Call History API provides endpoints for retrieving, streaming, and deleting call history records for an authenticated NFON Cloud Telephony user.


    This API is currently offered as part of **Login with NFON (Early Access)**. As an early access offering, the API is subject to change. Updates may occur on short notice, though we strive to provide advance notice where possible.


    For more information, see: https://www.nfon.com/en/integrations/login-with-nfon/'
  title: NFON Call History Accounts Customer Groups API
  version: 2.0-early-access
  termsOfService: https://www.nfon.com/en/legal/gtc
  contact:
    name: NFON
    email: integration@nfon.com
  license:
    name: NFON proprietary
servers:
- url: https://api.nfon.com/call-history
tags:
- name: Customer Groups
paths:
  /tenants/{participantExternalIdentifier}/targets/group-services/available-destinations-on-timeout:
    get:
      parameters:
      - schema:
          type: string
        required: true
        in: path
        name: participantExternalIdentifier
      tags:
      - Customer Groups
      operationId: get_176
      security:
      - oauth2:
        - tenant.manager
      - oauth2:
        - tenant.system-integrator
      - oauth2:
        - tenant.operator
      - oauth2:
        - tenant.admin
      responses:
        '200':
          content:
            application/vnd.collection.next+json:
              schema:
                $ref: '#/components/schemas/NfonApiCollectionResponse'
          description: Success
        '403':
          description: Insufficient permissions
        '404':
          description: Not found
  /tenants/{participantExternalIdentifier}/targets/group-services/{serviceNumber}/members:
    get:
      parameters:
      - schema:
          type: string
        required: true
        in: path
        name: serviceNumber
      - schema:
          type: string
        required: true
        in: path
        name: participantExternalIdentifier
      tags:
      - Customer Groups
      operationId: get_105
      security:
      - oauth2:
        - tenant.manager
      - oauth2:
        - tenant.system-integrator
      - oauth2:
        - tenant.operator
      - oauth2:
        - tenant.admin
      responses:
        '200':
          content:
            application/vnd.collection.next+json:
              schema:
                $ref: '#/components/schemas/NfonApiCollectionResponse'
          description: Success
        '403':
          description: Insufficient permissions
        '404':
          description: Not found
    post:
      requestBody:
        content:
          '*/*':
            schema:
              $ref: '#/components/schemas/NewGroupMemberRequest'
      parameters:
      - schema:
          type: string
        required: true
        in: path
        name: serviceNumber
      - schema:
          type: string
        required: true
        in: path
        name: participantExternalIdentifier
      tags:
      - Customer Groups
      operationId: post_31
      security:
      - oauth2:
        - tenant.manager
      - oauth2:
        - tenant.system-integrator
      - oauth2:
        - tenant.operator
      - oauth2:
        - tenant.admin
      responses:
        '403':
          description: Insufficient permissions
        '400':
          description: Validation error
        '201':
          description: Created
  /tenants/{participantExternalIdentifier}/targets/group-services/{serviceNumber}/inbound-trunk-numbers:
    get:
      parameters:
      - schema:
          type: string
        required: true
        in: path
        name: serviceNumber
      - schema:
          type: string
        required: true
        in: path
        name: participantExternalIdentifier
      tags:
      - Customer Groups
      operationId: list
      security:
      - oauth2:
        - tenant.manager
      - oauth2:
        - tenant.system-integrator
      - oauth2:
        - tenant.operator
      - oauth2:
        - tenant.admin
      responses:
        '200':
          content:
            application/vnd.collection.next+json:
              schema:
                $ref: '#/components/schemas/NfonApiCollectionResponse'
          description: Success
        '403':
          description: Insufficient permissions
        '404':
          description: Not found
    post:
      requestBody:
        content:
          '*/*':
            schema:
              $ref: '#/components/schemas/InboundTrunkNumberRequest'
      parameters:
      - schema:
          type: string
        required: true
        in: path
        name: serviceNumber
      - schema:
          type: string
        required: true
        in: path
        name: participantExternalIdentifier
      tags:
      - Customer Groups
      operationId: post_30
      security:
      - oauth2:
        - tenant.manager
      - oauth2:
        - tenant.system-integrator
      - oauth2:
        - tenant.operator
      - oauth2:
        - tenant.admin
      responses:
        '403':
          description: Insufficient permissions
        '400':
          description: Validation error
        '201':
          description: Created
  /tenants/{participantExternalIdentifier}/targets/group-services/{serviceNumber}:
    put:
      requestBody:
        content:
          '*/*':
            schema:
              $ref: '#/components/schemas/UpdateGroupRequest'
      parameters:
      - schema:
          format: int32
          type: integer
        required: true
        in: path
        name: serviceNumber
      - schema:
          type: string
        required: true
        in: path
        name: participantExternalIdentifier
      tags:
      - Customer Groups
      operationId: put_32
      security:
      - oauth2:
        - tenant.manager
      - oauth2:
        - tenant.system-integrator
      - oauth2:
        - tenant.operator
      - oauth2:
        - tenant.admin
      responses:
        '404':
          description: Not found
        '204':
          description: Updated
        '400':
          description: Validation error
        '403':
          description: Insufficient permissions
    delete:
      parameters:
      - schema:
          format: int32
          type: integer
        required: true
        in: path
        name: serviceNumber
      - schema:
          type: string
        required: true
        in: path
        name: participantExternalIdentifier
      tags:
      - Customer Groups
      operationId: delete_28
      security:
      - oauth2:
        - tenant.manager
      - oauth2:
        - tenant.system-integrator
      - oauth2:
        - tenant.operator
      - oauth2:
        - tenant.admin
      responses:
        '404':
          description: Not found
        '204':
          description: Deleted
        '403':
          description: Insufficient permissions
    get:
      parameters:
      - schema:
          format: int32
          type: integer
        required: true
        in: path
        name: serviceNumber
      - schema:
          type: string
        required: true
        in: path
        name: participantExternalIdentifier
      tags:
      - Customer Groups
      operationId: get_102
      security:
      - oauth2:
        - tenant.manager
      - oauth2:
        - tenant.system-integrator
      - oauth2:
        - tenant.operator
      - oauth2:
        - tenant.admin
      responses:
        '200':
          content:
            application/vnd.collection.next+json:
              schema:
                $ref: '#/components/schemas/NfonApiResponse'
              example:
                links:
                - href: /api/customers/K1234/groups/10/members
                  rel: members
                - href: /api/customers/K1234/groups/10/inbound-trunk-numbers
                  rel: inboundTrunkNumbers
                - href: /api/customers/K1234/groups/10/timeout
                  rel: timeout
                - href: /api/customers/K1234/groups/available-timeout-destinations
                  rel: availableTimeoutDestinations
                data:
                - value: 'true'
                  name: pickUpGroup
                href: /api/customers/example-id/targets/group-services/example-id
          description: Success
        '403':
          description: Insufficient permissions
        '404':
          description: Not found
  /tenants/{participantExternalIdentifier}/targets/group-services/{serviceNumber}/timeout:
    put:
      requestBody:
        content:
          '*/*':
            schema:
              $ref: '#/components/schemas/TimeoutRequest'
      parameters:
      - schema:
          format: int32
          type: integer
        required: true
        in: path
        name: serviceNumber
      - schema:
          type: string
        required: true
        in: path
        name: participantExternalIdentifier
      tags:
      - Customer Groups
      operationId: put_50
      security:
      - oauth2:
        - tenant.manager
      - oauth2:
        - tenant.system-integrator
      - oauth2:
        - tenant.operator
      - oauth2:
        - tenant.admin
      responses:
        '404':
          description: Not found
        '204':
          description: Updated
        '400':
          description: Validation error
        '403':
          description: Insufficient permissions
    delete:
      parameters:
      - schema:
          format: int32
          type: integer
        required: true
        in: path
        name: serviceNumber
      - schema:
          type: string
        required: true
        in: path
        name: participantExternalIdentifier
      tags:
      - Customer Groups
      operationId: delete_50
      security:
      - oauth2:
        - tenant.manager
      - oauth2:
        - tenant.system-integrator
      - oauth2:
        - tenant.operator
      - oauth2:
        - tenant.admin
      responses:
        '404':
          description: Not found
        '204':
          description: Deleted
        '403':
          description: Insufficient permissions
    get:
      parameters:
      - schema:
          format: int32
          type: integer
        required: true
        in: path
        name: serviceNumber
      - schema:
          type: string
        required: true
        in: path
        name: participantExternalIdentifier
      tags:
      - Customer Groups
      operationId: get_180
      security:
      - oauth2:
        - tenant.manager
      - oauth2:
        - tenant.system-integrator
      - oauth2:
        - tenant.operator
      - oauth2:
        - tenant.admin
      responses:
        '200':
          content:
            application/vnd.collection.next+json:
              schema:
                $ref: '#/components/schemas/NfonApiResponse'
              example:
                links:
                - href: /api/customers/K1234/groups/available-timeout-destinations
                  rel: availableDestinations
                - href: /api/customers/K1234/targets/services/5
                  rel: destinationOnTimeout
                data:
                - value: '30'
                  name: timeoutDelay
                href: /api/customers/example-id/targets/group-services/example-id/timeout
          description: Success
        '403':
          description: Insufficient permissions
        '404':
          description: Not found
  /tenants/{participantExternalIdentifier}/targets/group-services/{serviceNumber}/members/{extensionNumber}:
    delete:
      parameters:
      - schema:
          type: string
        required: true
        in: path
        name: extensionNumber
      - schema:
          type: string
        required: true
        in: path
        name: serviceNumber
      - schema:
          type: string
        required: true
        in: path
        name: participantExternalIdentifier
      tags:
      - Customer Groups
      operationId: delete_30
      security:
      - oauth2:
        - tenant.manager
      - oauth2:
        - tenant.system-integrator
      - oauth2:
        - tenant.operator
      - oauth2:
        - tenant.admin
      responses:
        '404':
          description: Not found
        '204':
          description: Deleted
        '403':
          description: Insufficient permissions
    get:
      parameters:
      - schema:
          type: string
        required: true
        in: path
        name: extensionNumber
      - schema:
          type: string
        required: true
        in: path
        name: serviceNumber
      - schema:
          type: string
        required: true
        in: path
        name: participantExternalIdentifier
      tags:
      - Customer Groups
      operationId: get_104
      security:
      - oauth2:
        - tenant.manager
      - oauth2:
        - tenant.system-integrator
      - oauth2:
        - tenant.operator
      - oauth2:
        - tenant.admin
      responses:
        '200':
          content:
            application/vnd.collection.next+json:
              schema:
                $ref: '#/components/schemas/NfonApiResponse'
              example:
                links:
                - href: /api/customers/K1234/phone-extensions/100
                  rel: phoneExtension
                data:
                - value: John Smith
                  name: displayName
                href: /api/customers/example-id/targets/group-services/example-id/members/example-id
          description: Success
        '403':
          description: Insufficient permissions
        '404':
          description: Not found
  /tenants/{participantExternalIdentifier}/targets/group-services/{serviceNumber}/inbound-trunk-numbers/{didNumber}:
    delete:
      parameters:
      - schema:
          type: string
        required: true
        in: path
        name: didNumber
      - schema:
          type: string
        required: true
        in: path
        name: serviceNumber
      - schema:
          type: string
        required: true
        in: path
        name: participantExternalIdentifier
      tags:
      - Customer Groups
      operationId: delete_29
      security:
      - oauth2:
        - tenant.manager
      - oauth2:
        - tenant.system-integrator
      - oauth2:
        - tenant.operator
      - oauth2:
        - tenant.admin
      responses:
        '404':
          description: Not found
        '204':
          description: Deleted
        '403':
          description: Insufficient permissions
    get:
      parameters:
      - schema:
          type: string
        required: true
        in: path
        name: didNumber
      - schema:
          type: string
        required: true
        in: path
        name: serviceNumber
      - schema:
          type: string
        required: true
        in: path
        name: participantExternalIdentifier
      tags:
      - Customer Groups
      operationId: get_103
      security:
      - oauth2:
        - tenant.manager
      - oauth2:
        - tenant.system-integrator
      - oauth2:
        - tenant.operator
      - oauth2:
        - tenant.admin
      responses:
        '200':
          content:
            application/vnd.collection.next+json:
              schema:
                $ref: '#/components/schemas/NfonApiResponse'
          description: Success
        '403':
          description: Insufficient permissions
        '404':
          description: Not found
  /tenants/{participantExternalIdentifier}/targets/group-services:
    get:
      parameters:
      - schema:
          type: string
        required: true
        in: path
        name: participantExternalIdentifier
      tags:
      - Customer Groups
      operationId: get_101
      security:
      - oauth2:
        - tenant.manager
      - oauth2:
        - tenant.system-integrator
      - oauth2:
        - tenant.operator
      - oauth2:
        - tenant.admin
      responses:
        '200':
          content:
            application/vnd.collection.next+json:
              schema:
                $ref: '#/components/schemas/NfonApiCollectionResponse'
          description: Success
        '403':
          description: Insufficient permissions
    post:
      requestBody:
        content:
          '*/*':
            schema:
              $ref: '#/components/schemas/NewGroupRequest'
      parameters:
      - schema:
          type: string
        required: true
        in: path
        name: participantExternalIdentifier
      tags:
      - Customer Groups
      operationId: post_29
      security:
      - oauth2:
        - tenant.manager
      - oauth2:
        - tenant.system-integrator
      - oauth2:
        - tenant.operator
      - oauth2:
        - tenant.admin
      responses:
        '403':
          description: Insufficient permissions
        '400':
          description: Validation error
        '201':
          description: Created
components:
  schemas:
    NoLinks:
      type: object
    String:
      properties:
        notNull:
          type: boolean
        notPresent:
          type: boolean
        present:
          type: boolean
        presentNotNull:
          type: boolean
        presentNull:
          type: boolean
        value:
          type: string
      type: object
      description: Link to the last page
    TimeoutRequest:
      properties:
        links:
          $ref: '#/components/schemas/TimeoutLinks'
        data:
          $ref: '#/components/schemas/Data'
        items:
          items:
            type: object
          type: array
        itemCount:
          format: int32
          type: integer
      type: object
    NfonApiResponse:
      properties:
        links:
          $ref: '#/components/schemas/Links'
        data:
          description: Resource data (name/value pairs or structured object)
          type: object
        href:
          example: /api/sip-servers/100
          type: string
          description: Self-link to this resource
      type: object
      description: Standard API response envelope for a single resource
    NewGroupRequest:
      properties:
        links:
          $ref: '#/components/schemas/NoLinks'
        data:
          $ref: '#/components/schemas/Data'
        items:
          items:
            type: object
          type: array
        itemCount:
          format: int32
          type: integer
      type: object
    TimeoutLinks:
      type: object
    NewGroupMemberRequest:
      properties:
        links:
          $ref: '#/components/schemas/NewGroupMemberLinks'
        data:
          $ref: '#/components/schemas/NoData'
        items:
          items:
            type: object
          type: array
        itemCount:
          format: int32
          type: integer
      type: object
    NfonApiCollectionResponse:
      oneOf:
      - $ref: '#/components/schemas/NfonApiCollectionResponsePage'
      - $ref: '#/components/schemas/NfonApiCollectionResponseNonPage'
      type: object
      description: Collection response envelope
    NoData:
      type: object
    InboundTrunkNumberRequest:
      properties:
        links:
          $ref: '#/components/schemas/InboundTrunkNumberLinks'
        data:
          $ref: '#/components/schemas/InboundTrunkNumberData'
        items:
          items:
            type: object
          type: array
        itemCount:
          format: int32
          type: integer
      type: object
    NewGroupMemberLinks:
      properties:
        phoneExtension:
          type: string
      type: object
    PUTLinks:
      properties:
        inboundTrunkNumbers:
          $ref: '#/components/schemas/String'
        members:
          $ref: '#/components/schemas/String'
      type: object
    UpdateGroupRequest:
      properties:
        links:
          $ref: '#/components/schemas/PUTLinks'
        data:
          $ref: '#/components/schemas/Data'
        items:
          items:
            type: object
          type: array
        itemCount:
          format: int32
          type: integer
      type: object
    NfonApiCollectionResponsePage:
      properties:
        links:
          $ref: '#/components/schemas/CollectionLinks'
        offset:
          example: 0
          description: Current page offset
          format: int64
          type: integer
        total:
          example: 42
          description: Total number of items in the collection
          format: int64
          type: integer
        items:
          type: array
          items:
            $ref: '#/components/schemas/NfonApiResponse'
          description: Items in this page
        size:
          example: 20
          description: Number of items in this page
          format: int32
          type: integer
        href:
          description: Self-link to this collection
          type: string
      type: object
      description: Paginated collection response envelope
    Data:
      properties:
        key:
          type: string
          description: Metadata key.
          example: function_key_number
        value:
          type: string
          description: Metadata value.
          example: '5'
      type: object
      required:
      - key
      - value
      description: Data represents key-value pair for additional reference metadata.
    InboundTrunkNumberData:
      properties:
        didExtension:
          example: '123456'
          type: string
      type: object
    CollectionLinks:
      properties:
        first:
          $ref: '#/components/schemas/String'
        prev:
          $ref: '#/components/schemas/String'
        next:
          $ref: '#/components/schemas/String'
        last:
          $ref: '#/components/schemas/String'
      type: object
      description: Pagination links for collection responses
    Links:
      description: Related resource links
      type: object
    NfonApiCollectionResponseNonPage:
      properties:
        links:
          $ref: '#/components/schemas/Links'
        href:
          description: Self-link to this collection
          type: string
        items:
          type: array
          items:
            $ref: '#/components/schemas/NfonApiResponse'
          description: All items in the collection
      type: object
      description: Non-paginated collection response envelope
    InboundTrunkNumberLinks:
      properties:
        trunk:
          type: string
      type: object
  securitySchemes:
    bearer_auth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: JSON Web Token