Buk

Buk Items API

The Items API from Buk — 4 operation(s) for items.

Operations 5

POST /assigns Asignar un ítem #
PATCH /assigns/{id} Editar una asignación #
DELETE /assigns/{id} Eliminar una asignación #
POST /assigns/{id}/terminate Terminar una asignación de ítem #
GET /employees/{id}/assigns Show employee's item assignments #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/buk-items-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

buk-items-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  description: '# Buk Data Access API.


    To use the API, you need to obtain an **API Key**.

    You can manage access within the platform, in **Settings => API Access.**


    Once an API Key is created, you must send the value as a header in the HTTP request, in the `auth_token` field.


    ## For more details, you can review the article "How to integrate with Buk through an API"


    # Endpoints'
  title: Buk Items API
servers:
- url: https://demo.buk.cl/api/v1/brasil
tags:
- name: Items
paths:
  /assigns:
    post:
      summary: Asignar un ítem
      description: 'No se recomienda el uso de este endpoint para cliente grandes. Para operaciones masivas se recomienda usar el endpoint de **Sincronización datos de pago**.


        Asigna un nuevo ítem a un empleado en el sistema.


        - `employee_id`: Id del empleado al cual se asignará un ítem.

        - `item_id`: Id del ítem el cual se asignará al usuario.

        - `start_date`: Mes de inicio para esta asignación.

        - `end_date`: (opcional) Mes de término para esta asignación.

        - `description`: (opcional) Descripción a mostrar en la liquidación.

        - `amount`: Monto de la asignación. Requerido sólo para ítems de tipo variable.

        - `advance_payment_day`: (opcional) Día del mes en el que se paga el ítem si es de tipo anticipo.

        - `overwrite_existing_assign`: (opcional) [boolean] Indica que se quiere emular el

        comportamiento del importador masivo. Esto es, permitir sobreescribir la asignación en caso de que ya exista.

        - `cost_center`: (opcional) [string] Código de la definición de centro de costos, debe estar habilitada la general Habilitar Centro Costo Bonos.

        - `custom_attrs`: (opcional) [object] Atributos personalizados de la asignación, como pares clave-valor.


        **Permisos requeridos para utilizar este endpoint:**

        * Permisos de ítems en: ''Lectura y Modificación''.'
      tags:
      - Items
      responses:
        '200':
          description: Se devuelve la asignación creada.
          content:
            application/json:
              schema:
                properties:
                  message:
                    type: string
                  item:
                    $ref: '#/components/schemas/Assign'
            application/pdf:
              schema:
                properties:
                  message:
                    type: string
                  item:
                    $ref: '#/components/schemas/Assign'
        '400':
          description: Faltan datos que son obligatorios.
        '404':
          description: El empleado `employee_id` o el bono `item_id` no existen.
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Assign__Create'
        required: true
      operationId: postAssigns
      x-operation-id-source: derived
  /assigns/{id}:
    patch:
      summary: Editar una asignación
      description: 'Prefiera el uso del endpoint de **Sincronización datos de pago**


        Se modifica una Asignación del sistema.


        Se debe enviar como JSON un objeto tipo Assign en el cuerpo de la petición,

        compuesto por los siguientes atributos


        - `cost_center`: (opcional) [string] Código de la definición de centro de costos, debe estar habilitada la general Habilitar Centro Costo Bonos.

        - `amount`: Monto de la asignación. Requerido solo para ítems de tipo variable

        - `custom_attrs`: (opcional) [object] Atributos personalizados de la asignación, como pares clave-valor.


        La asignación tiene que ser de un bono variable para poder cambiar el monto.


        **Permisos requeridos para utilizar este endpoint:**

        * Permisos de ítems en: ''Lectura y Modificación''.'
      tags:
      - Items
      deprecated: true
      parameters:
      - name: id
        in: path
        description: id de la asignación
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Respuesta de la api ante el termino de la asignación.
          content:
            application/json:
              schema:
                properties:
                  message:
                    type: string
                  assign:
                    $ref: '#/components/schemas/Assign'
            application/pdf:
              schema:
                properties:
                  message:
                    type: string
                  assign:
                    $ref: '#/components/schemas/Assign'
        '400':
          description: Existe un error con los datos enviados
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/bad_request'
            application/pdf:
              schema:
                $ref: '#/components/schemas/bad_request'
      requestBody:
        content:
          application/json:
            schema:
              properties:
                amount:
                  type: integer
                  format: integer
                cost_center:
                  type: string
                custom_attrs:
                  type: object
        description: Objeto de tipo assign
      operationId: patchAssignsById
      x-operation-id-source: derived
    delete:
      summary: Eliminar una asignación
      description: 'Elimina una asignación.


        **Permisos requeridos para utilizar este endpoint:**

        * Permisos de ítems en: ''Lectura y Modificación''.'
      tags:
      - Items
      parameters:
      - name: id
        in: path
        description: id de la asignación
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Respuesta de la api ante la eliminación de la asignación.
          content:
            application/json:
              schema:
                properties:
                  deleted:
                    type: boolean
            application/pdf:
              schema:
                properties:
                  deleted:
                    type: boolean
        '503':
          description: No se pudo procesar la solicitud. Intente nuevamente.
          content:
            application/json:
              schema:
                properties:
                  error:
                    type: string
            application/pdf:
              schema:
                properties:
                  error:
                    type: string
        '404':
          description: No Existe el recurso solicitado
          name: errors
          content:
            application/json:
              schema:
                properties:
                  errors:
                    type: array
                    items:
                      type: string
            application/pdf:
              schema:
                properties:
                  errors:
                    type: array
                    items:
                      type: string
        '400':
          description: Existe un error con los datos enviados
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/bad_request'
            application/pdf:
              schema:
                $ref: '#/components/schemas/bad_request'
      operationId: deleteAssignsById
      x-operation-id-source: derived
  /assigns/{id}/terminate:
    post:
      summary: Terminar una asignación de ítem
      description: 'Termina la asignación de un ítem.


        Se debe enviar como JSON la fecha de término (opcional) en el cuerpo de la petición,

        en caso de no enviarla su valor será el período actual.


        La fechas deben estar en formato YYYY-MM-DD.


        **Permisos requeridos para utilizar este endpoint:**

        * Permisos de ítems en: ''Lectura y Modificación''.'
      tags:
      - Items
      parameters:
      - name: id
        in: path
        description: id de la asignación
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Respuesta de la api ante el termino de la asignación.
          content:
            application/json:
              schema:
                properties:
                  message:
                    type: string
            application/pdf:
              schema:
                properties:
                  message:
                    type: string
        '400':
          description: Existe un error con los datos enviados
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/bad_request'
            application/pdf:
              schema:
                $ref: '#/components/schemas/bad_request'
      requestBody:
        content:
          application/json:
            schema:
              properties:
                end_date:
                  type: string
                  format: date
        description: fecha de término
      operationId: postAssignsByIdTerminate
      x-operation-id-source: derived
  /employees/{id}/assigns:
    get:
      summary: Show employee's item assignments
      description: 'Returns the current assignments of an employee along with basic information of the assigned item.


        Each assignment consists of:

        - id: unique identifier of the assignment

        - item: item assigned to the employee

        - amount: for items configured with "different amount per person", this value corresponds to that entered in the assignment, and for items configured with "same amount for all" this value will be the amount of the item entered at its creation. For a formulated item, it represents the value of `item.amount`

        - start_date: start period for this assignment

        - end_date: end period for the assignment

        - custom_attrs: the object includes a custom attribute with its respective value. If there is no custom attribute configured, this will not appear in the response


        Each item consists of:

        - id: unique identifier of the item

        - code: item code


        The start date of the period (optional) must be sent as JSON in the body of the request.


        The date must be in YYYY-MM-DD format.


        **Permisos requeridos para utilizar este endpoint:**

        * Employee permissions en: ''Lectura''.

        * Item permissions en: ''Lectura''.

        * Allow viewing sensitive information en: ''Sí''.'
      tags:
      - Items
      parameters:
      - name: id
        in: path
        description: ID of the employee to be queried
        required: true
        schema:
          type: string
      - name: date
        in: query
        description: Filter the active added items for this date
        schema:
          type: string
          format: date
      - name: page_size
        in: query
        description: '(OPTIONAL) Number of answers per page. By default, it has a value of 25 and must be within a range of [25 - 100].

          '
        schema:
          type: integer
      - name: page
        in: query
        description: Page number
        schema:
          type: integer
      responses:
        '200':
          description: As a response, we receive an array (data) with the information of the added items
          content:
            application/json:
              schema:
                properties:
                  pagination:
                    $ref: '#/components/schemas/Pagination'
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Employee__Assign'
            application/pdf:
              schema:
                properties:
                  pagination:
                    $ref: '#/components/schemas/Pagination'
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Employee__Assign'
        '400':
          description: There is an error with the data submitted
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/bad_request'
            application/pdf:
              schema:
                $ref: '#/components/schemas/bad_request'
      operationId: getEmployeesByIdAssigns
      x-operation-id-source: derived
components:
  schemas:
    Employee__Assign:
      properties:
        id:
          type: integer
        item:
          $ref: '#/components/schemas/Bono__Minimal'
        amount:
          type: number
        start_date:
          type: string
          format: date
        end_date:
          type: string
          format: date
        description:
          type: string
        custom_attrs:
          type: object
    Pagination:
      properties:
        next:
          type: string
        previous:
          type: string
        count:
          type: integer
        total_pages:
          type: integer
    Assign__Create:
      properties:
        employee_id:
          required: true
          type: integer
        item_id:
          required: true
          type: integer
        start_date:
          required: true
          type: string
          format: date
        end_date:
          type: string
          format: date
        description:
          type: string
        amount:
          required: true
          type: integer
        advance_payment_day:
          type: integer
        overwrite_existing_assign:
          type: boolean
          default: false
        cost_center:
          type: string
        custom_attrs:
          type: object
    Assign:
      properties:
        id:
          type: integer
        item_id:
          type: integer
        employee_id:
          type: integer
        start_date:
          type: string
          format: date
        end_date:
          type: string
          format: date
        amount:
          type: integer
        advance_payment_day:
          type: integer
        description:
          type: string
        cost_center:
          type: string
    bad_request:
      properties:
        errors:
          type: array
          items:
            type: string
    Bono__Minimal:
      properties:
        id:
          type: integer
        code:
          type: string
  securitySchemes:
    auth_token:
      type: apiKey
      name: auth_token
      in: header