SafeLine · Capability

SafeLine Management API — Users

SafeLine Management API — Users. 7 operations. Lead operation: List Users. Self-contained Naftiko capability covering one Safeline business surface.

Run with Naftiko SafelineUsers

What You Can Do

GET
Listusers — List Users
/v1/api/userapi
POST
Createuser — Create User
/v1/api/userapi
PUT
Updateuser — Update User
/v1/api/userapi
DELETE
Deleteuser — Delete User
/v1/api/userapi
GET
Listapitokens — List API Tokens
/v1/api/userapitokenapi
POST
Createapitoken — Create API Token
/v1/api/userapitokenapi
DELETE
Deleteapitoken — Delete API Token
/v1/api/userapitokenapi

MCP Tools

list-users

List Users

read-only idempotent
create-user

Create User

update-user

Update User

idempotent
delete-user

Delete User

idempotent
list-api-tokens

List API Tokens

read-only idempotent
create-api-token

Create API Token

delete-api-token

Delete API Token

idempotent

Capability Spec

management-users.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: SafeLine Management API — Users
  description: 'SafeLine Management API — Users. 7 operations. Lead operation: List Users. Self-contained Naftiko capability
    covering one Safeline business surface.'
  tags:
  - Safeline
  - Users
  created: '2026-05-19'
  modified: '2026-05-19'
binds:
- namespace: env
  keys:
    SAFELINE_API_KEY: SAFELINE_API_KEY
capability:
  consumes:
  - type: http
    namespace: management-users
    baseUri: https://{host}:9443
    description: SafeLine Management API — Users business capability. Self-contained, no shared references.
    resources:
    - name: api-UserAPI
      path: /api/UserAPI
      operations:
      - name: listusers
        method: GET
        description: List Users
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: page
          in: query
          type: integer
        - name: page_size
          in: query
          type: integer
      - name: createuser
        method: POST
        description: Create User
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
      - name: updateuser
        method: PUT
        description: Update User
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
      - name: deleteuser
        method: DELETE
        description: Delete User
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: api-UserAPITokenAPI
      path: /api/UserAPITokenAPI
      operations:
      - name: listapitokens
        method: GET
        description: List API Tokens
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
      - name: createapitoken
        method: POST
        description: Create API Token
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
      - name: deleteapitoken
        method: DELETE
        description: Delete API Token
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    authentication:
      type: apikey
      key: X-SLCE-API-Token
      value: '{{env.SAFELINE_API_KEY}}'
      placement: header
  exposes:
  - type: rest
    namespace: management-users-rest
    port: 8080
    description: REST adapter for SafeLine Management API — Users. One Spectral-compliant resource per consumed operation,
      prefixed with /v1.
    resources:
    - path: /v1/api/userapi
      name: api-userapi
      description: REST surface for api-UserAPI.
      operations:
      - method: GET
        name: listusers
        description: List Users
        call: management-users.listusers
        with:
          page: rest.page
          page_size: rest.page_size
        outputParameters:
        - type: object
          mapping: $.
      - method: POST
        name: createuser
        description: Create User
        call: management-users.createuser
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
      - method: PUT
        name: updateuser
        description: Update User
        call: management-users.updateuser
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
      - method: DELETE
        name: deleteuser
        description: Delete User
        call: management-users.deleteuser
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/api/userapitokenapi
      name: api-userapitokenapi
      description: REST surface for api-UserAPITokenAPI.
      operations:
      - method: GET
        name: listapitokens
        description: List API Tokens
        call: management-users.listapitokens
        outputParameters:
        - type: object
          mapping: $.
      - method: POST
        name: createapitoken
        description: Create API Token
        call: management-users.createapitoken
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
      - method: DELETE
        name: deleteapitoken
        description: Delete API Token
        call: management-users.deleteapitoken
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
  - type: mcp
    namespace: management-users-mcp
    port: 9090
    transport: http
    description: MCP adapter for SafeLine Management API — Users. One tool per consumed operation, routed inline through this
      capability's consumes block.
    tools:
    - name: list-users
      description: List Users
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: management-users.listusers
      with:
        page: tools.page
        page_size: tools.page_size
      outputParameters:
      - type: object
        mapping: $.
    - name: create-user
      description: Create User
      hints:
        readOnly: false
        destructive: false
        idempotent: false
      call: management-users.createuser
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: update-user
      description: Update User
      hints:
        readOnly: false
        destructive: false
        idempotent: true
      call: management-users.updateuser
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: delete-user
      description: Delete User
      hints:
        readOnly: false
        destructive: true
        idempotent: true
      call: management-users.deleteuser
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: list-api-tokens
      description: List API Tokens
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: management-users.listapitokens
      outputParameters:
      - type: object
        mapping: $.
    - name: create-api-token
      description: Create API Token
      hints:
        readOnly: false
        destructive: false
        idempotent: false
      call: management-users.createapitoken
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: delete-api-token
      description: Delete API Token
      hints:
        readOnly: false
        destructive: true
        idempotent: true
      call: management-users.deleteapitoken
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.