CometAI API - Endpoints Deep Dive

Summary

This article covers the various user-facing CometAI API endpoints available to users. It includes a detailed description of each endpoint, example API requests and URLs, sample request bodies, expected response formats, and guidance on how to test and view responses using Postman. The article also explains the expected data returned by each endpoint, common success and error responses, and provides examples of what a successful API call looks like.

Body

Table of Contents

Context

This article covers the various user-facing CometAI API endpoints available to users. It includes a detailed description of each endpoint, example API requests and URLs, sample request bodies, expected response formats, and guidance on how to test and view responses using Postman. The article also explains the expected data returned by each endpoint, common success and error responses, and provides examples of what a successful API call looks like.

User-Facing Endpoints

Designed for general developers, integration agents, and client-facing interfaces. These APIs facilitate core session execution, model capability discovery, asset uploads, and tag curation. 

  • Model Queries: /available_models (GET) 
  • Core Conversations: /chat (POST) 
  • Ingestion Pipeline: /files/upload (POST) 
  • Catalog Lookups: /files/query (POST) 
  • Tag Directory: /files/tags/list (GET) 
  • Tag Generation: /files/tags/create (POST) 
  • Tag Purging: /files/tags/delete (POST) 
  • Asset Assignment: /files/set_tags (POST) 
  • Assistant Inventory: /assistant/list (GET) 
  • Assistant Provisioning: /assistant/create (POST) 
  • Assistant Sharing: /assistant/share (POST) 
  • Assistant Deletion: /assistant/delete (POST) 

Testing in Postman 

Follow these exact steps from our verified testing workflow: 

  1. Set Request Type: Change the request dropdown menu on the left to GET/POST
  2. Input URL: Paste for e.g. https://api.cometai.utdallas.edu/available_models in the address field. 
  3. Authorization: 
    • Click the Authorization tab. 
    • From the Auth Type dropdown, select Bearer Token. 
    • In the Token text box on the right, paste your valid API key. 
  4. Body Tab: Click the Body tab, select the none radio button to verify that the payload is empty. 
  5. Send Request: Click the blue Send button in the upper-right corner. 

Postman Example

Uploaded Image (Thumbnail)

Endpoint Testing

1. Endpoint: /available_models (GET) 

Purpose: Retrieves a dynamically updated list of large language models configured for CometAI, detailing operational parameters such as input context window, token limits, system prompt options, and reasoning support. 

Authentication: 

  • Authorization Protocol: Bearer Token 
  • Token Value: <comet-token> (Configured via Headers or Auth setup tab) 

Endpoint: 

GET https://api.cometai.utdallas.edu/available_models 

Detailed Specification

Expected Data 

Responses 

N/A 

200: List of available models and CometAI’s set default, cheapest, and advanced models. 
Content: application/json 
    models (list of model objects) 
    default (object) 
    cheapest (object) 
    advanced (object) 

Example Body 

Example Response 

N/A 

  "success": true, 

  "data": { 

    "models": [ 

      {"id": "gpt-4o-mini", 

        "name": "GPT-4o-mini", 

        "description": "Consider it for its ability to output longer responses and deliver rapid replies with advanced comprehension. GPT-4o Mini is OpenAI’s most cost-efficient small model. Trained on information available through October 2023.", 

        "inputContextWindow": 128000, 

        "outputTokenLimit": 16384, 

        "supportsImages": true, 

        "provider": "Azure", 

        “supportsSystemPrompts”:true,  

        “systemPrompt”: “Additional prompt” 

      }], 

    "default”: <model Object>, 

    "advanced<model Object>, 

    "cheapest": <model Object> } 

Postman Verification Screenshot 

Uploaded Image (Thumbnail)

Back to Top

2. Endpoint: /chat (POST) 

Purpose: Offers real-time chat capabilities exclusively through streaming. Interact with a selection of the most advanced AI chat models available in CometAI. 

Authentication: 

  • Authorization Protocol: Bearer Token 
  • Token Value: <comet-token> 

Endpoint: 

POST https://api.cometai.utdallas.edu/chat 

Detailed Specification 

Expected Data 

Responses 

temperature (number) 
max_tokens (integer) 
dataSources (array of strings) 
    - strings represent the data source Ids. Obtain data source ids in the following ways: 

  1. Call the /files/query endpoint.  

  1. Upload a new data source using the /files/upload endpoint, the id is returned as the key attribute. 

 

messages (array of objects): 
     - role (string): Required. 

       Options include: 

        -  system 

        - assistant 

        - user. 
    - content (string): Required. 
type (string): Options include prompt. 
options (object): 
  - dataSourceOptions (object) 
  - ragOnly (boolean) 
  - skipRag (boolean) 
  - assistantId (string) 
  - model (object) Required. To get model Ids, make a request to the /available_models endpoint: 
       - id (string) 
  - prompt (string) 

200: Chat stream response. 
Content: application/json 

   success (boolean) 

   message (string) 
    data (string) 
400: Bad request, invalid or missing fields. 
401: Unauthorized, invalid authentication credentials. 
403: Forbidden, request refused. 
404: Not found, resource not found. 

Example Body 

Example Response 


     "data":{ 
         "temperature": 0.7, 
         "max_tokens": 4000, 
         "dataSources": [“netid@utdallas.edu/l80.json” 
or 
“netid@utdallas.edu/date/l80.json], 
         "messages": [ 
             { 
             "role": "user", 
             "content": "What is the mascot of UT Dallas?" 
             } 
         ], 
         "options": { 
             "ragOnly": false, 
             "skipRag": true, 
             "model": {“id”: "gpt-4o"}, 
             "prompt": "What is the capital of France?", 
           “assistantId”:”astp/abcdefghi” 
         } 
     } 


     "success": true, 
     "message": "Chat completed successfully", 
     "data": "The mascot of UT Dallas is Temoc." 

Postman Verification Screenshot 

Uploaded Image (Thumbnail)

Back to Top

3. Endpoint: /files/upload (POST) 

Purpose: Initiates file system upload requests, rendering temporary presigned AWS S3 repository ingestion pipelines for indexing, vector database integration, or document execution. 

Authentication: 

  • Authorization Protocol: Bearer Token 
  • Token Value: <comet-token> 

Endpoint:

POST https://api.cometai.utdallas.edu/files/upload 

Detailed Specification

Expected Data 

Responses 

name (string): Required.  

   Options include: 

   - saveAsData 

   - createChunks 

   - ingestRag 

   - makeDownloadable 

   - extractText 
params (object) 
type (string): Required. 
name (string): Required. 
knowledgeBase (string): Required. 
tags (array of strings): Required. 
data (object): Required. 

200: File upload process initiated or completed successfully. 
Content: application/json 
    success (boolean) 
    uploadUrl (string, nullable) 
    statusUrl (string, nullable) 
    contentUrl (string, nullable) 
    metadataUrl (string, nullable) 
    key (string, nullable) 
400: Bad request, incorrect or missing parameters. 
401: User does not have access to the file upload functionality. 

Example Body 

Example Response 


     "data":{ 
         "type": "application/fileExtension", 
         "name": "fileName.pdf", 
         "knowledgeBase": "default", 
         "tags": [], 
         "data": {} 

}} 


     "success": true, 
     "uploadUrl": "<uploadUrl>", 
     "statusUrl": "<statusUrl>", 
     "contentUrl": "<contentUrl>", 
     "metadataUrl": "<metadataUrl>", 
     "key": "netid@utdallas.edu/date/293088.json

Postman Verification Screenshot 

Uploaded Image (Thumbnail)

Back to Top

4. Endpoint: /files/query (POST) 

Purpose: View a list of uploaded CometAI data sources stored inside the cloud sandbox environment. 

Authentication: 

  • Authorization Protocol: Bearer Token 

Endpoint: 

POST https://api.cometai.utdallas.edu/files/query 

Detailed Specification 

Expected Data 

Responses 

startDate (string, date-time):   

   Default is 2021-01-01T00:00:00Z. 
pageSize (integer):  

   Default is 10. 
pageKey (object): 
  - id (string) 
  - createdAt (string) 
  - type (string) 
namePrefix (string or null) 

 

createdAtPrefix (string or null) 
typePrefix (string or null) 
types (array of strings):    

   Default is an empty array. 
tags (array of strings):  

   Default is an empty array. 
pageIndex (integer):  

   Default is 0. 
forwardScan (boolean):  

   Default is false. 
sortIndex (string):  

   Default is createdAt. 

200: Returns a list of files that match the query criteria. 
Content: application/json 
     success (boolean) 
     data (object) 
     items (array of objects) 
     pageKey (object): Key to retrieve the next page of results 

Example Body 

Example Response 


     "data":{ 
         "pageSize": 2, 
         "sortIndex": "", 
         "forwardScan": false 
         } 


     "success": true, 
     "data": { 
         "items": [ 
             { 
                 "createdAt": "2024-07-15T17:12:45.046682", 
                 "updatedBy": "netid@utdallas.edu", 
                 "createdBy": "netid@utdallas.edu", 
                 "name": "fileName.doc", 
                 "knowledgeBase": "default", 
                 "data": {}, 
                 "updatedAt": "2024-07-15T17:12:45.046700", 
                 "totalTokens": 12644, 
                 "dochash": "25ef6a3e472d8dbe501915c1", 
                 "id":     

                "netid@utdallas.edu/date/2389020943.json", 
                 "tags": [], 
                 "totalItems": 1025, 
                 "type": "application/fileExtension" 
             } ] } } 

Postman Verification Screenshot 

Uploaded Image (Thumbnail)

Back to Top

5. Endpoint: /files/tags/list (GET) 

Purpose: View a list of your custom workspace tags associated with your data sources, active conversations, and assistants. 

Endpoint:

GET https://api.cometai.utdallas.edu/files/tags/list 

Detailed Specification 

Expected Data 

Responses 

N/A 

200: A list of tags. 
Content: application/json 
     success (boolean) 
     data (object) 
     tags (array of strings) 

Example Body 

Example Response 

N/A 


     "success": true, 
     "data": { 
         "tags": [ 
             "NewTag" 
         ]}} 

Postman Verification Screenshot 

Uploaded Image (Thumbnail)

Back to Top

6. Endpoint: /files/tags/create (POST) 

Purpose: Create new custom platform tags that can be tied to your documents and assistants. 

Endpoint: 

POST https://api.cometai.utdallas.edu/files/tags/create 

Detailed Specification 

Expected Data 

Responses 

tags (array of strings): Default is an empty array. 

200: Result of tag creation. 
Content: application/json 
     success (boolean) 
     message (string) 

Example Body 

Example Response 


     "data": { 
         "tags": ["NewTag"] 
     } 


     "success": true, 
     "message": "Tags added successfully" 

Postman Verification Screenshot 

Uploaded Image (Thumbnail)

Back to Top

7. Endpoint: /files/tags/delete (POST) 

Purpose: Deletes an assigned platform tag, purging its active references from associated data sources. 

Endpoint: 

POST https://api.cometai.utdallas.edu/files/tags/delete 

Detailed Specification 

Delete a file tag. 

Expected Data 

Responses 

tag (string): Required. 

200: Result of tag deletion. 
Content: application/json 
    success (boolean) 
    message (string) 

Example Body 

Example Response 


     "data":{ 
         "tag": "NewTag" 
     } 


     "success": true, 
     "message": "Tag deleted successfully" 

Postman Verification Screenshot

Uploaded Image (Thumbnail)

Back to Top

8. Endpoint: /files/set_tags (POST) 

Purpose: Associate a CometAI tag with a specific data source, conversation, or assistant. 

Endpoint:

POST https://api.cometai.utdallas.edu/files/set_tags 

Detailed Specification 

Expected Data 

Responses 

id (string): Required. 
tags (array of strings): Default is an empty array. 

200: Result of setting file tags. 
Content: application/json 
     success (boolean) 
     message (string) 

Example Body 

Example Response 


     "data":{ 
         "id": "netid@utdallas.edu/date/290208.json", 
         "tags": ["NewTag"] 
     } 


     "success": true, 
     "message": "Tags updated and added to user" 

Postman Verification Screenshot

Uploaded Image (Thumbnail)

Back to Top

9. Endpoint: /assistant/list (GET) 

Purpose: Retrieve a list of all custom assistants configured on your CometAI platform domain. 

Authentication: 

  • Authorization Protocol: Bearer Token 

Endpoint: 

GET https://api.cometai.utdallas.edu/assistant/list 

Detailed Specification 

Expected Data 

Responses 

N/A 

200: List of assistants retrieved successfully. 
Content: application/json 
    success (boolean) 
    message (string) 
     data (array) 

Example Body 

Example Response 

N/A 


   "success": true, 
   "message": "Assistants retrieved successfully", 
   "data": [ 
     { 
       "assistantId": "astp/498370528-38594", 
       "version": 3, 
       "instructions": "<instructions>", 
       "disclaimerHash": "348529340098580234959824580-pueiorupo4", 
       "coreHash": "eiouqent84832n8989pdeer", 
       "user": "netid@utdallas.edu", 
       "uri": null, 
       "createdAt": "2024-07-15T19:07:57", 
       "dataSources": [ 
         { 
           "metadata": "<metadata>", 
           "data": "", 
           "name": "api_documentation.yml", 
           "raw": "", 
           "id": "global/7834905723785897982345088927.content.json", 
           "type": "application/x-yaml", 
...<More Data>... 

Postman Verification Screenshot 

Uploaded Image (Thumbnail)

Back to Top

10. Endpoint: /assistant/share (POST) 

Purpose: Share a customized CometAI assistant with other internal organizational users. 

Endpoint: 

POST https://api.cometai.utdallas.edu/assistant/share 

Detailed Specification 

Expected Data 

Responses 

assistantId (string): Required. 
recipientUsers (array of strings): Required. 
note (string) 

200: Assistant sharing response. 
Content: application/json 
    success (boolean) 
    message (string) 

Example Body 

Example Response 


     "data":{ 
         "assistantId": "ast/8934572093982034020-9", 
         "recipientUsers": ["netid@utdallas.edu"], 
         "note": "check this out!" 
     } 


     "success": false, 
     "message": "Unable to share with some users", 
     "failedShares": [ 
         "netid@utdallas.edu
     ] 

Postman Verification Screenshot 

Uploaded Image (Thumbnail)

Note: For the assistant/share endpoint, the ["sucess": false] in the response body actually means the endpoint is working. This is a boolean False which actually means True. Also, status 200 confirms that the endpoint is working. 
Back to Top

11. Endpoint: /assistant/create (POST) 

Purpose: Create or update a customizable CometAI assistant, detailing operational scopes, files, system constraints, and prompt formatting instructions. 

Endpoint: 

POST https://api.cometai.utdallas.edu/assistant/create 

Detailed Specification 

Expected Data 

Responses 

name (string): Required. 
description (string): Required. 
assistantId (string):  

    Needed if updating an existing assistant.  

   We will provide you with one if creating a new assistant 
tags (array of strings): Required. 
instructions (string): Required. 
disclaimer (string) 
uri (string or null) 
dataSources (array of objects): Required. 
  - Entire Data Source object 
dataSourceOptions (array of objects): 
  - insertAttachedDocumentsMetadata (boolean)  

    Includes Attached Data Source Metadata in Prompt 
  - insertAttachedDocuments (boolean)  

    Includes Attached Documents in Prompt 
  - insertConversationDocuments (boolean) 

    Includes Conversation Documents in Prompt 
  - disableDataSources (boolean)  

    Disable Data Source Insertion 
  - insertConversationDocumentsMetadata (boolean)  

    Include Conversation Data Source Metadata in Prompt 
  - ragConversationDocuments (boolean) 

    Include Conversation Documents in RAG 
  - ragAttachedDocuments (boolean)  

    Include Attached Documents in RAG 

200: Assistant creation response. 
Content: application/json 
    success (boolean) 
    message (string) 
    data (object) 

Example Body 

Example Response 


     "data": { 
         "name": "Sample Assistant 3", 
         "description": "This is a sample assistant for demonstration purposes", 
         "assistantId": "", 
         "tags": ["test"], 
         "instructions": "Respond to user queries about general knowledge topics", 
         "disclaimer": "This assistant's responses are for informational purposes only", 
         "dataSources": [{'id': 'e48759073324384kjsf', 'name': 'api_paths_summary.csv', 'type': 'text/csv', 'raw': '', 'data': '', 'key': 'netid@utdallas.edu/date/w3ou009we3.json ', 'metadata': {'name': 'api_paths_summary.csv', 'totalItems': 20, 'locationProperties': ['row_number'], 'contentKey': 'netid@utdallas.edu/date/w3ou009we3.json.content.json', 'createdAt': '2024-07-15T18:58:24.912235', 'totalTokens': 3750, 'tags': [], 'props': {}}}], 
         "tools": [] 
     } 


     "success": true, 
     "message": "Assistant created successfully", 
     "data": { 
         "assistantId": "astp/3io4u5ipy34jkelkdfweiorwur", 
         "id": "ast/03uio3904583049859482", 
         "version": 1 
     } 

Postman Verification Screenshot 

Uploaded Image (Thumbnail)

Back to Top

12. Endpoint: /assistant/delete (POST) 

Purpose: Delete an existing custom assistant registration instance. 

Endpoint: 

POST https://api.cometai.utdallas.edu/assistant/delete 

Detailed Specification 

Delete an Amplify assistant. 

Expected Data 

Responses 

assistantId (string): Required. 

200: Assistant deletion response. 
Content: application/json 
    success (boolean) 
    message (string) 

Example Body 

Example Response 


     "data":{ 
         "assistantId": "astp/3209457834985793094" 
     } 


     "success": true, 
     "message": "Assistant deleted successfully." 

Postman Verification Screenshot

Uploaded Image (Thumbnail)

Back to Top

Details

Details

Article ID: 1589
Created
Mon 7/27/26 5:37 PM
Modified
Tue 7/28/26 10:12 AM