openapi: 3.1.0 info: title: Helpcenter AccountComments API version: 1.0.0 tags: - name: AccountComments paths: /api/v1/accounts/{accountId}/comments/{commentId}: get: tags: - AccountComments summary: Get an account comment description: This API fetches an account comment from the portal. operationId: getAccountComment parameters: - name: include in: query description: Secondary information related to the comments. Value allowed is mentions, which returns the details of users mentioned in the comments. required: false style: simple explode: true schema: type: - 'null' - array description: Secondary information related to the comments. Value allowed is @mentions@, which returns the details of users mentioned in the comments. items: type: - string - 'null' enum: - mentions maxLength: 100 minLength: 0 uniqueItems: true - $ref: '#/components/parameters/accountId' - $ref: '#/components/parameters/commentId' - $ref: ./Common.json#/components/parameters/orgId responses: '200': $ref: '#/components/responses/get_accountComment_Response' security: - iam-oauth2-schema: - Desk.contacts.READ x-audience: - external-public put: tags: - AccountComments summary: Update an account comment description: This API updates an existing account comment. operationId: updateAccountComment parameters: - $ref: '#/components/parameters/accountId' - $ref: '#/components/parameters/commentId' - $ref: ./Common.json#/components/parameters/orgId requestBody: $ref: '#/components/requestBodies/editAccountCommentRequestBody' responses: '200': $ref: '#/components/responses/accountCommentCommonResponse' security: - iam-oauth2-schema: - Desk.contacts.UPDATE x-audience: - external-public delete: tags: - AccountComments summary: Delete an account comment description: This API deletes an existing account comment. operationId: deleteAccountComment parameters: - $ref: '#/components/parameters/accountId' - $ref: '#/components/parameters/commentId' - $ref: ./Common.json#/components/parameters/orgId responses: '200': $ref: ./Common.json#/components/responses/emptyResponse security: - iam-oauth2-schema: - Desk.contacts.UPDATE x-audience: - external-public /api/v1/accounts/{accountId}/comments: get: tags: - AccountComments summary: List all account comments description: This API lists a particular number of comments recorded on an account, based on the limit specified. operationId: getAccountComments parameters: - name: include in: query description: Secondary information related to the comments. Value allowed is mentions, which returns the details of users mentioned in the comments. required: false style: simple explode: true schema: type: - 'null' - array description: Secondary information related to the comments. Value allowed is @mentions@, which returns the details of users mentioned in the comments. items: type: - string - 'null' enum: - mentions maxLength: 100 minLength: 0 uniqueItems: true - name: limit in: query description: No. of comments to fetch required: false style: form explode: true schema: type: - string - 'null' - integer format: int32 description: No. of comments to fetch maximum: 100 minimum: 1 pattern: ([0-9]+) - name: from in: query description: Index number starting from which the comments must be fetched. required: false style: form explode: true schema: type: - string - 'null' - integer format: int32 description: Index number starting from which the comments must be fetched. pattern: ([0-9]+) - name: sortBy in: query description: 'sortby can be @commentedTime@. default order : commentedTime in descending order , prefix @-@ denotes desc' required: false style: form explode: true schema: type: - string - 'null' description: 'sortby can be @commentedTime@. default order : commentedTime in descending order , prefix @-@ denotes desc' enum: - commentedTime maxLength: 100 minLength: 0 - $ref: '#/components/parameters/accountId' - $ref: ./Common.json#/components/parameters/orgId responses: '200': $ref: '#/components/responses/getAccountComments' security: - iam-oauth2-schema: - Desk.contacts.READ x-audience: - external-public post: tags: - AccountComments summary: Create an account comment description: This API adds a comment to an account. operationId: createAccountComment parameters: - $ref: '#/components/parameters/accountId' - $ref: ./Common.json#/components/parameters/orgId requestBody: $ref: '#/components/requestBodies/addAccountCommentRequestBody' responses: '422': $ref: ./Common.json#/components/responses/multipleUnprocessEntityResponse '200': $ref: '#/components/responses/accountCommentCommonResponse' security: - iam-oauth2-schema: - Desk.contacts.UPDATE x-audience: - external-public components: requestBodies: addAccountCommentRequestBody: content: application/json: schema: type: - 'null' - object additionalProperties: false properties: contentType: type: - string - 'null' enum: - plainText - html maxLength: 100 minLength: 0 content: type: - string - 'null' maxLength: 32000 minLength: 0 required: - content examples: Valid requestBody Definitions: value: contentType: html content: First account comment editAccountCommentRequestBody: content: application/json: schema: type: - 'null' - object additionalProperties: false properties: content: type: - string - 'null' maxLength: 32000 minLength: 0 examples: Valid requestBody Definitions: value: content: second account comment edit responses: accountCommentCommonResponse: description: accountCommentCommonResponse template definitions content: application/json: schema: $ref: '#/components/schemas/accountCommentCommonResponse' examples: Valid responses Definitions: value: modifiedTime: null commentedTime: 1485287121000 id: '4000000530047' contentType: plainText commenterId: '4000000008692' content: second account comment edit commenter: firstName: Jade lastName: Tywin photoURL: https://desk.zoho.com/api/v1/agents/4000000008692/photo?orgId=292828 name: Jade Tywin roleName: LightAgent type: AGENT email: jade12tywin@zylker.com getAccountComments: description: getAccountComments template definitions content: application/json: schema: allOf: - type: object properties: data: type: array items: type: object properties: mention: $ref: '#/components/schemas/mentions' - type: - 'null' - object additionalProperties: false properties: data: $ref: ./AccountComments.json#/components/schemas/dataArr required: - data examples: Valid responses Definitions: value: data: - modifiedTime: null commentedTime: 1485287155000 id: '4000000530049' contentType: plainText commenterId: '4000000008692' content: Sample zsu[@user:55616589]zsu and zsu[@team:31138000001254025_new team]zsu testing mention: - firstName: '' lastName: pandees photoURL: null offSet: '7' length: '28' id: '31138000000573164' type: AGENT email: jade15tywin@zylker.com zuid: '55616589' - offSet: '39' length: '46' name: new team id: '31138000001254025' type: TEAM - offSet: '59' departmentId: '3113800000634345' length: '26' id: '3113800000143134' type: TICKET commenter: firstName: Jade lastName: Tywin photoURL: https://desk.zoho.com/api/v1/agents/4000000008692/photo?orgId=292828 name: Jade Tywin roleName: LightAgent type: AGENT email: jade12tywin@zylker.com - modifiedTime: 1485287184000 commentedTime: 1485287121000 id: '4000000530047' contentType: html commenterId: '4000000008692' content: Sample zsu[@user:55616589]zsu and zsu[@team:31138000001254025_new team]zsu testing mention: - firstName: '' lastName: pandees photoURL: null offSet: '7' length: '28' id: '31138000000573164' type: AGENT email: jade15tywin@zylker.com zuid: '55616589' - offSet: '39' length: '46' name: new team id: '31138000001254025' type: TEAM - offSet: '59' departmentId: '3113800000634345' entityNumber: '1342' length: '26' name: '' id: '3113800000143134' type: TICKET commenter: firstName: Jade lastName: Tywin photoURL: https://desk.zoho.com/api/v1/agents/4000000008692/photo?orgId=292828 name: Jade Tywin roleName: LightAgent type: AGENT email: jade12tywin@zylker.com get_accountComment_Response: description: get AccountComment template definitions content: application/json: schema: allOf: - $ref: '#/components/schemas/accountCommentCommonResponse' - type: object properties: mention: $ref: '#/components/schemas/mentions' parameters: accountId: name: accountId in: path required: true style: simple explode: false schema: type: - string - 'null' - integer format: int64 pattern: ([0-9]+) commentId: name: commentId in: path required: true style: simple explode: false schema: type: - string - 'null' - integer format: int64 pattern: ([0-9]+) schemas: mentions: type: - 'null' - array items: type: - 'null' - object additionalProperties: false maxProperties: 9 minProperties: 9 properties: firstName: type: - string - 'null' maxLength: 50 minLength: 0 lastName: type: - string - 'null' maxLength: 50 minLength: 0 photoURL: type: - string - 'null' maxLength: 100 minLength: 0 pattern: ([0-9a-zA-Z_\-\.\$@\?\,\:\'\/\!\P{InBasicLatin}\s])+ offset: type: - string - 'null' - integer format: int32 pattern: ([0-9]+) length: type: - string - 'null' - integer format: int32 pattern: ([0-9]+) id: type: - string - 'null' - integer format: int64 pattern: ([0-9]+) type: type: - string - 'null' enum: - AGENT - TEAM maxLength: 100 minLength: 0 email: type: - string - 'null' maxLength: 100 minLength: 0 pattern: ^[a-zA-Z0-9\_]([a-zA-Z0-9\_\+\-\.\'&]*)@(?=.{4,256}$)(([a-zA-Z0-9]+)(([\-\_]*[a-zA-Z0-9])*)[\.])+[a-zA-Z]{2,22}$ zuid: type: - string - 'null' - integer format: int32 pattern: ([0-9]+) required: - email - firstName - id - lastName - length - offset - photoURL - type - zuid uniqueItems: false accountCommentCommonResponse: type: - 'null' - object additionalProperties: false properties: modifiedTime: type: - string - 'null' maxLength: 100 minLength: 0 pattern: (((19|20)\d\d)[-/.]{1}(0?[1-9]|1[012])[-/.]{1}(0?[1-9]|[12][0-9]|3[01])(T)([01]?[0-9]|2[0-3]):[0-5]?[0-9]:[0-5]?[0-9]([/.][\d]{0,3})?(Z)) encodedContent: type: - string - 'null' maxLength: 100 minLength: 0 commentedTime: type: - string - 'null' maxLength: 100 minLength: 0 pattern: (((19|20)\d\d)[-/.]{1}(0?[1-9]|1[012])[-/.]{1}(0?[1-9]|[12][0-9]|3[01])(T)([01]?[0-9]|2[0-3]):[0-5]?[0-9]:[0-5]?[0-9]([/.][\d]{0,3})?(Z)) id: type: - string - 'null' - integer format: int64 pattern: ([0-9]+) contentType: type: - string - 'null' enum: - plainText - html maxLength: 100 minLength: 0 commenterId: type: - string - 'null' - integer format: int64 pattern: ([0-9]+) content: type: - string - 'null' maxLength: 32000 minLength: 0 commenter: $ref: ./AccountComments.json#/components/schemas/commenter impersonatedUser: $ref: ./TicketComment.json#/components/schemas/impersonatedUser required: - commentedTime - commenter - commenterId - content - contentType - encodedContent - id - impersonatedUser - modifiedTime securitySchemes: iam-oauth2-schema: $ref: ./Common.json#/components/securitySchemes/iam-oauth2-schema x-entity: Helpcenter