All URIs are relative to http://localhost:1000
Method | HTTP request | Description |
---|---|---|
ConversationsCreateFromAsset | POST /conversations/create/from_asset/{asset} | /conversations/create/from_asset/{asset} [POST] |
ConversationsCreateSpecificConversation | POST /conversations/create | /conversations/create [POST] |
ConversationsDeleteSpecificConversation | POST /conversations/{conversation}/delete | /conversations/{conversation}/delete [POST] |
ConversationsIdentifiersSnapshot | GET /conversations/identifiers | /conversations/identifiers [GET] |
ConversationsSnapshot | GET /conversations | /conversations [GET] |
ConversationsStreamIdentifiers | GET /conversations/stream/identifiers | /conversations/stream/identifiers [WS] |
SearchConversations | POST /conversations/search | /conversations/search [POST] |
ConversationsCreateFromAssetOutput ConversationsCreateFromAsset (Guid asset)
/conversations/create/from_asset/{asset} [POST]
Creates a conversation based on an asset. It initiates a conversation and generates an initial message that includes a summary of the asset used as contextual grounding.
using System.Collections.Generic;
using System.Diagnostics;
using Pieces.Os.Core.Api;
using Pieces.Os.Core.Client;
using Pieces.Os.Core.SdkModel;
namespace Example
{
public class ConversationsCreateFromAssetExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://localhost:1000";
// Configure API key authorization: application
config.AddApiKey("X-Application-ID", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// config.AddApiKeyPrefix("X-Application-ID", "Bearer");
var apiInstance = new ConversationsApi(config);
var asset = 2254f2c8-5797-40e8-ac56-41166dc0e159; // Guid | The id (uuid) of the asset that you are trying to access.
try
{
// /conversations/create/from_asset/{asset} [POST]
ConversationsCreateFromAssetOutput result = apiInstance.ConversationsCreateFromAsset(asset);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling ConversationsApi.ConversationsCreateFromAsset: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
This returns an ApiResponse object which contains the response data, status code and headers.
try
{
// /conversations/create/from_asset/{asset} [POST]
ApiResponse<ConversationsCreateFromAssetOutput> response = apiInstance.ConversationsCreateFromAssetWithHttpInfo(asset);
Debug.Write("Status Code: " + response.StatusCode);
Debug.Write("Response Headers: " + response.Headers);
Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
Debug.Print("Exception when calling ConversationsApi.ConversationsCreateFromAssetWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
Name | Type | Description | Notes |
---|---|---|---|
asset | Guid | The id (uuid) of the asset that you are trying to access. |
ConversationsCreateFromAssetOutput
- Content-Type: Not defined
- Accept: application/json, text/plain
Status code | Description | Response headers |
---|---|---|
200 | OK | - |
500 | Internal Server Error | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Conversation ConversationsCreateSpecificConversation (bool? transferables = null, SeededConversation seededConversation = null)
/conversations/create [POST]
Creates a specific conversation.
using System.Collections.Generic;
using System.Diagnostics;
using Pieces.Os.Core.Api;
using Pieces.Os.Core.Client;
using Pieces.Os.Core.SdkModel;
namespace Example
{
public class ConversationsCreateSpecificConversationExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://localhost:1000";
// Configure API key authorization: application
config.AddApiKey("X-Application-ID", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// config.AddApiKeyPrefix("X-Application-ID", "Bearer");
var apiInstance = new ConversationsApi(config);
var transferables = true; // bool? | This is a boolean that will decided if we are want to return the transferable data (default) or not(performance enhancement) (optional)
var seededConversation = new SeededConversation(); // SeededConversation | (optional)
try
{
// /conversations/create [POST]
Conversation result = apiInstance.ConversationsCreateSpecificConversation(transferables, seededConversation);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling ConversationsApi.ConversationsCreateSpecificConversation: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
This returns an ApiResponse object which contains the response data, status code and headers.
try
{
// /conversations/create [POST]
ApiResponse<Conversation> response = apiInstance.ConversationsCreateSpecificConversationWithHttpInfo(transferables, seededConversation);
Debug.Write("Status Code: " + response.StatusCode);
Debug.Write("Response Headers: " + response.Headers);
Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
Debug.Print("Exception when calling ConversationsApi.ConversationsCreateSpecificConversationWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
Name | Type | Description | Notes |
---|---|---|---|
transferables | bool? | This is a boolean that will decided if we are want to return the transferable data (default) or not(performance enhancement) | [optional] |
seededConversation | SeededConversation | [optional] |
- Content-Type: application/json
- Accept: application/json, text/plain
Status code | Description | Response headers |
---|---|---|
200 | OK | - |
500 | Internal Server Error | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
void ConversationsDeleteSpecificConversation (string conversation)
/conversations/{conversation}/delete [POST]
Deletes a specific conversation.
using System.Collections.Generic;
using System.Diagnostics;
using Pieces.Os.Core.Api;
using Pieces.Os.Core.Client;
using Pieces.Os.Core.SdkModel;
namespace Example
{
public class ConversationsDeleteSpecificConversationExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://localhost:1000";
// Configure API key authorization: application
config.AddApiKey("X-Application-ID", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// config.AddApiKeyPrefix("X-Application-ID", "Bearer");
var apiInstance = new ConversationsApi(config);
var conversation = "conversation_example"; // string | This is the uuid of a conversation.
try
{
// /conversations/{conversation}/delete [POST]
apiInstance.ConversationsDeleteSpecificConversation(conversation);
}
catch (ApiException e)
{
Debug.Print("Exception when calling ConversationsApi.ConversationsDeleteSpecificConversation: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
This returns an ApiResponse object which contains the response data, status code and headers.
try
{
// /conversations/{conversation}/delete [POST]
apiInstance.ConversationsDeleteSpecificConversationWithHttpInfo(conversation);
}
catch (ApiException e)
{
Debug.Print("Exception when calling ConversationsApi.ConversationsDeleteSpecificConversationWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
Name | Type | Description | Notes |
---|---|---|---|
conversation | string | This is the uuid of a conversation. |
void (empty response body)
- Content-Type: Not defined
- Accept: text/plain
Status code | Description | Response headers |
---|---|---|
204 | No Content | - |
500 | Internal Server Error | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FlattenedConversations ConversationsIdentifiersSnapshot ()
/conversations/identifiers [GET]
Retrieves all the UUIDs associated with a Conversation.
using System.Collections.Generic;
using System.Diagnostics;
using Pieces.Os.Core.Api;
using Pieces.Os.Core.Client;
using Pieces.Os.Core.SdkModel;
namespace Example
{
public class ConversationsIdentifiersSnapshotExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://localhost:1000";
// Configure API key authorization: application
config.AddApiKey("X-Application-ID", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// config.AddApiKeyPrefix("X-Application-ID", "Bearer");
var apiInstance = new ConversationsApi(config);
try
{
// /conversations/identifiers [GET]
FlattenedConversations result = apiInstance.ConversationsIdentifiersSnapshot();
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling ConversationsApi.ConversationsIdentifiersSnapshot: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
This returns an ApiResponse object which contains the response data, status code and headers.
try
{
// /conversations/identifiers [GET]
ApiResponse<FlattenedConversations> response = apiInstance.ConversationsIdentifiersSnapshotWithHttpInfo();
Debug.Write("Status Code: " + response.StatusCode);
Debug.Write("Response Headers: " + response.Headers);
Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
Debug.Print("Exception when calling ConversationsApi.ConversationsIdentifiersSnapshotWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
This endpoint does not need any parameter.
- Content-Type: Not defined
- Accept: application/json, text/plain
Status code | Description | Response headers |
---|---|---|
200 | OK | - |
500 | Internal Server Error | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Conversations ConversationsSnapshot (bool? transferables = null)
/conversations [GET]
Retrieves a snapshot of a specific conversation.
using System.Collections.Generic;
using System.Diagnostics;
using Pieces.Os.Core.Api;
using Pieces.Os.Core.Client;
using Pieces.Os.Core.SdkModel;
namespace Example
{
public class ConversationsSnapshotExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://localhost:1000";
// Configure API key authorization: application
config.AddApiKey("X-Application-ID", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// config.AddApiKeyPrefix("X-Application-ID", "Bearer");
var apiInstance = new ConversationsApi(config);
var transferables = true; // bool? | This is a boolean that will decided if we are want to return the transferable data (default) or not(performance enhancement) (optional)
try
{
// /conversations [GET]
Conversations result = apiInstance.ConversationsSnapshot(transferables);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling ConversationsApi.ConversationsSnapshot: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
This returns an ApiResponse object which contains the response data, status code and headers.
try
{
// /conversations [GET]
ApiResponse<Conversations> response = apiInstance.ConversationsSnapshotWithHttpInfo(transferables);
Debug.Write("Status Code: " + response.StatusCode);
Debug.Write("Response Headers: " + response.Headers);
Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
Debug.Print("Exception when calling ConversationsApi.ConversationsSnapshotWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
Name | Type | Description | Notes |
---|---|---|---|
transferables | bool? | This is a boolean that will decided if we are want to return the transferable data (default) or not(performance enhancement) | [optional] |
- Content-Type: Not defined
- Accept: application/json, text/plain
Status code | Description | Response headers |
---|---|---|
200 | OK | - |
500 | Internal Server Error | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
void ConversationsStreamIdentifiers ()
/conversations/stream/identifiers [WS]
Provides a WebSocket connection that emits changes to your conversation identifiers (UUIDs).
using System.Collections.Generic;
using System.Diagnostics;
using Pieces.Os.Core.Api;
using Pieces.Os.Core.Client;
using Pieces.Os.Core.SdkModel;
namespace Example
{
public class ConversationsStreamIdentifiersExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://localhost:1000";
// Configure API key authorization: application
config.AddApiKey("X-Application-ID", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// config.AddApiKeyPrefix("X-Application-ID", "Bearer");
var apiInstance = new ConversationsApi(config);
try
{
// /conversations/stream/identifiers [WS]
apiInstance.ConversationsStreamIdentifiers();
}
catch (ApiException e)
{
Debug.Print("Exception when calling ConversationsApi.ConversationsStreamIdentifiers: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
This returns an ApiResponse object which contains the response data, status code and headers.
try
{
// /conversations/stream/identifiers [WS]
apiInstance.ConversationsStreamIdentifiersWithHttpInfo();
}
catch (ApiException e)
{
Debug.Print("Exception when calling ConversationsApi.ConversationsStreamIdentifiersWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
This endpoint does not need any parameter.
void (empty response body)
- Content-Type: Not defined
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
SearchedConversations SearchConversations (bool? transferables = null, SearchInput searchInput = null)
/conversations/search [POST]
This will search your conversations for a specific conversation note: we will search annotations, the name of the conversation, and the conversation messages
using System.Collections.Generic;
using System.Diagnostics;
using Pieces.Os.Core.Api;
using Pieces.Os.Core.Client;
using Pieces.Os.Core.SdkModel;
namespace Example
{
public class SearchConversationsExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://localhost:1000";
// Configure API key authorization: application
config.AddApiKey("X-Application-ID", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// config.AddApiKeyPrefix("X-Application-ID", "Bearer");
var apiInstance = new ConversationsApi(config);
var transferables = true; // bool? | This is a boolean that will decided if we are want to return the transferable data (default) or not(performance enhancement) (optional)
var searchInput = new SearchInput(); // SearchInput | (optional)
try
{
// /conversations/search [POST]
SearchedConversations result = apiInstance.SearchConversations(transferables, searchInput);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling ConversationsApi.SearchConversations: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
This returns an ApiResponse object which contains the response data, status code and headers.
try
{
// /conversations/search [POST]
ApiResponse<SearchedConversations> response = apiInstance.SearchConversationsWithHttpInfo(transferables, searchInput);
Debug.Write("Status Code: " + response.StatusCode);
Debug.Write("Response Headers: " + response.Headers);
Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
Debug.Print("Exception when calling ConversationsApi.SearchConversationsWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
Name | Type | Description | Notes |
---|---|---|---|
transferables | bool? | This is a boolean that will decided if we are want to return the transferable data (default) or not(performance enhancement) | [optional] |
searchInput | SearchInput | [optional] |
- Content-Type: application/json
- Accept: application/json, text/plain
Status code | Description | Response headers |
---|---|---|
200 | OK | - |
500 | Internal Server Error | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]