Engagedly Businesses API

Handle business unit operations

OpenAPI Specification

engagedly-businesses-api-openapi.yml Raw ↑
openapi: 3.0.3
info:
  title: Engagedly Activities Businesses API
  description: 'REST API for the Engagedly people strategy execution platform. Provides endpoints for managing users, departments, locations, job titles, business units, permissions, user attributes, and employee activities such as praises and recognition. Supports performance review workflows, goal management, and organizational data integration using header-based authentication with ClientKey and SecretKey.

    '
  version: beta
  contact:
    url: https://engagedly.com
  license:
    name: Proprietary
servers:
- url: https://api.engagedly.com/beta
  description: Production API server
security:
- clientKeyAuth: []
  secretKeyAuth: []
tags:
- name: Businesses
  description: Handle business unit operations
paths:
  /businesses:
    get:
      operationId: listBusinesses
      summary: List all businesses
      description: Returns a paginated list of all business units in the organization.
      tags:
      - Businesses
      parameters:
      - $ref: '#/components/parameters/pageParam'
      - $ref: '#/components/parameters/sizeParam'
      responses:
        '200':
          description: Paginated list of business units
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BusinessListResponse'
        '401':
          $ref: '#/components/responses/Unauthorized'
    post:
      operationId: createBusiness
      summary: Create a new business
      description: Creates a new business unit in the organization.
      tags:
      - Businesses
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BusinessRequest'
      responses:
        '201':
          description: Business created successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BusinessSingleResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
  /businesses/{id}:
    get:
      operationId: getBusiness
      summary: Get a single business
      description: Returns details for a single business unit including its members.
      tags:
      - Businesses
      parameters:
      - $ref: '#/components/parameters/idPathParam'
      responses:
        '200':
          description: Business details
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BusinessSingleResponse'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
    put:
      operationId: updateBusiness
      summary: Update an existing business
      description: Updates the name and/or members of an existing business unit.
      tags:
      - Businesses
      parameters:
      - $ref: '#/components/parameters/idPathParam'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BusinessRequest'
      responses:
        '200':
          description: Business updated successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BusinessSingleResponse'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
    delete:
      operationId: deleteBusiness
      summary: Delete a business
      description: Permanently deletes the specified business unit.
      tags:
      - Businesses
      parameters:
      - $ref: '#/components/parameters/idPathParam'
      responses:
        '204':
          description: Business deleted successfully
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
components:
  responses:
    Unauthorized:
      description: Unauthorized — invalid or missing ClientKey/SecretKey
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
    BadRequest:
      description: Bad request — missing or invalid parameters
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
    NotFound:
      description: Not Found — resource does not exist
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
  schemas:
    BusinessRequest:
      type: object
      required:
      - name
      properties:
        name:
          type: string
        members:
          type: array
          items:
            type: string
          description: Array of user IDs
    Business:
      type: object
      properties:
        id:
          type: string
          example: f5afec62-21ff-40d3-a06e-9a2162ef6b69
        name:
          type: string
          example: Manufacturing Unit
        members_count:
          type: string
          example: '10'
        administrators_count:
          type: string
          example: '2'
        members:
          type: array
          items:
            $ref: '#/components/schemas/UserRef'
    ErrorResponse:
      type: object
      properties:
        error_type:
          type: string
          enum:
          - api_connection_error
          - authentication_error
          - invalid_request_error
          - validation_error
          example: validation_error
        errors:
          type: array
          items:
            $ref: '#/components/schemas/ErrorDetail'
    ErrorDetail:
      type: object
      properties:
        field:
          type: string
          example: name
        message:
          type: string
          example: Mandatory attribute missing
        code:
          type: string
          example: missing_field
    UserRef:
      type: object
      properties:
        id:
          type: string
        name:
          type: string
        email:
          type: string
          format: email
        first_name:
          type: string
        middle_name:
          type: string
          nullable: true
        last_name:
          type: string
        display_picture:
          $ref: '#/components/schemas/DisplayPicture'
        is_admin:
          type: boolean
          nullable: true
    BusinessSingleResponse:
      type: object
      properties:
        success:
          type: boolean
        data:
          $ref: '#/components/schemas/Business'
    BusinessListResponse:
      type: object
      properties:
        success:
          type: boolean
        pagination:
          $ref: '#/components/schemas/Pagination'
        data:
          type: array
          items:
            $ref: '#/components/schemas/Business'
    Pagination:
      type: object
      properties:
        page:
          type: integer
          example: 1
        size:
          type: integer
          example: 25
        has_more:
          type: boolean
          example: false
        total_records:
          type: integer
          example: 42
    DisplayPicture:
      type: object
      properties:
        large:
          type: string
          format: uri
          nullable: true
        medium:
          type: string
          format: uri
          nullable: true
        small:
          type: string
          format: uri
          nullable: true
        original:
          type: string
          format: uri
          nullable: true
        reduced:
          type: string
          format: uri
          nullable: true
  parameters:
    pageParam:
      name: page
      in: query
      description: Page number (starts at 1)
      schema:
        type: integer
        minimum: 1
        default: 1
    sizeParam:
      name: size
      in: query
      description: Number of records per page (maximum 50)
      schema:
        type: integer
        minimum: 1
        maximum: 50
        default: 25
    idPathParam:
      name: id
      in: path
      required: true
      description: The unique identifier of the resource
      schema:
        type: string
  securitySchemes:
    clientKeyAuth:
      type: apiKey
      in: header
      name: ClientKey
      description: Client key obtained from the Engagedly portal under Integrations > Engagedly API
    secretKeyAuth:
      type: apiKey
      in: header
      name: SecretKey
      description: Secret key obtained from the Engagedly portal. Shown only once upon generation.