chore: Move agent availability to Account level (#3074)
- Move agent availability to the account level
This commit is contained in:
42
swagger/paths/application/agents/create.yml
Normal file
42
swagger/paths/application/agents/create.yml
Normal file
@@ -0,0 +1,42 @@
|
||||
tags:
|
||||
- Agent
|
||||
operationId: add-new-agent-to-account
|
||||
summary: Add a New Agent
|
||||
description: Add a new Agent to Account
|
||||
security:
|
||||
- userApiKey: []
|
||||
parameters:
|
||||
- name: data
|
||||
in: body
|
||||
required: true
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
name:
|
||||
type: string
|
||||
description: Full Name of the agent
|
||||
required: true
|
||||
email:
|
||||
type: string
|
||||
description: Email of the Agent
|
||||
required: true
|
||||
role:
|
||||
type: string
|
||||
enum: ['agent', 'administrator']
|
||||
description: Whether its administrator or agent
|
||||
required: true
|
||||
availability_status:
|
||||
type: string
|
||||
enum: ['available', 'busy', 'offline']
|
||||
description: The availability status of the agent.
|
||||
auto_offline:
|
||||
type: boolean
|
||||
description: Whether the availability status of agent is configured to go offline automatically when away.
|
||||
responses:
|
||||
200:
|
||||
description: Success
|
||||
schema:
|
||||
description: 'Newly Created Agent'
|
||||
$ref: '#/definitions/agent'
|
||||
403:
|
||||
description: Access denied
|
||||
21
swagger/paths/application/agents/delete.yml
Normal file
21
swagger/paths/application/agents/delete.yml
Normal file
@@ -0,0 +1,21 @@
|
||||
tags:
|
||||
- Agent
|
||||
operationId: delete-agent-from-account
|
||||
summary: Remove an Agent from Account
|
||||
description: Remove an Agent from Account
|
||||
security:
|
||||
- userApiKey: []
|
||||
parameters:
|
||||
- in: path
|
||||
name: id
|
||||
schema:
|
||||
type: integer
|
||||
required: true
|
||||
description: The ID of the agent to be deleted
|
||||
responses:
|
||||
200:
|
||||
description: Success
|
||||
404:
|
||||
description: Agent not found
|
||||
403:
|
||||
description: Access denied
|
||||
17
swagger/paths/application/agents/index.yml
Normal file
17
swagger/paths/application/agents/index.yml
Normal file
@@ -0,0 +1,17 @@
|
||||
tags:
|
||||
- Agent
|
||||
operationId: get-account-agents
|
||||
summary: List Agents in Account
|
||||
description: Get Details of Agents in an Account
|
||||
security:
|
||||
- userApiKey: []
|
||||
responses:
|
||||
200:
|
||||
description: Success
|
||||
schema:
|
||||
type: array
|
||||
description: 'Array of all active agents'
|
||||
items:
|
||||
$ref: '#/definitions/agent'
|
||||
403:
|
||||
description: Access denied
|
||||
42
swagger/paths/application/agents/update.yml
Normal file
42
swagger/paths/application/agents/update.yml
Normal file
@@ -0,0 +1,42 @@
|
||||
tags:
|
||||
- Agent
|
||||
operationId: update-agent-in-account
|
||||
summary: Update Agent in Account
|
||||
description: Update an Agent in Account
|
||||
security:
|
||||
- userApiKey: []
|
||||
parameters:
|
||||
- in: path
|
||||
name: id
|
||||
schema:
|
||||
type: integer
|
||||
required: true
|
||||
description: The ID of the agent to be updated.
|
||||
- name: data
|
||||
in: body
|
||||
required: true
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
role:
|
||||
type: string
|
||||
enum: ['agent', 'administrator']
|
||||
description: Whether its administrator or agent
|
||||
required: true
|
||||
availability_status:
|
||||
type: string
|
||||
enum: ['available', 'busy', 'offline']
|
||||
description: The availability status of the agent.
|
||||
auto_offline:
|
||||
type: boolean
|
||||
description: Whether the availability status of agent is configured to go offline automatically when away.
|
||||
responses:
|
||||
200:
|
||||
description: Success
|
||||
schema:
|
||||
description: 'The updated agent'
|
||||
$ref: '#/definitions/agent'
|
||||
404:
|
||||
description: Agent not found
|
||||
403:
|
||||
description: Access denied
|
||||
Reference in New Issue
Block a user