GET Get agent configuration
{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId
QUERY PARAMS

wId
sId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId"

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/assistant/agent_configurations/:sId HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId"))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/assistant/agent_configurations/:sId',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId');
$request->setMethod(HTTP_METH_GET);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/assistant/agent_configurations/:sId")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId"

response = requests.get(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId"

response <- VERB("GET", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/assistant/agent_configurations/:sId') do |req|
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId";

    let client = reqwest::Client::new();
    let response = client.get(url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId
http GET {{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId
wget --quiet \
  --method GET \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "agentConfiguration": {
    "id": 12345,
    "sId": "7f3a9c2b1e",
    "version": 2,
    "versionCreatedAt": "2023-06-15T14:30:00Z",
    "versionAuthorId": "0ec9852c2f",
    "name": "Customer Support Agent",
    "description": "An AI agent designed to handle customer support inquiries",
    "instructions": "Always greet the customer politely and try to resolve their issue efficiently.",
    "pictureUrl": "https://example.com/agent-images/support-agent.png",
    "status": "active",
    "scope": "workspace",
    "userFavorite": true,
    "actions": [],
    "maxStepsPerRun": 10,
    "templateId": "b4e2f1a9c7"
  }
}
GET List agents
{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations
QUERY PARAMS

wId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations"

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/assistant/agent_configurations HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations"))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/assistant/agent_configurations',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations');
$request->setMethod(HTTP_METH_GET);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/assistant/agent_configurations")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations"

response = requests.get(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations"

response <- VERB("GET", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/assistant/agent_configurations') do |req|
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations";

    let client = reqwest::Client::new();
    let response = client.get(url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations
http GET {{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations
wget --quiet \
  --method GET \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
GET Search agents by name
{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search
QUERY PARAMS

q
wId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q=");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search" {:query-params {:q ""}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q="

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q="),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q=");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q="

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/assistant/agent_configurations/search?q= HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q=")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q="))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q=")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q=")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q=');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search',
  params: {q: ''}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q=';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q=',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q=")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/assistant/agent_configurations/search?q=',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search',
  qs: {q: ''}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search');

req.query({
  q: ''
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search',
  params: {q: ''}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q=';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q="]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q=" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q=",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q=');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search');
$request->setMethod(HTTP_METH_GET);

$request->setQueryData([
  'q' => ''
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search');
$request->setRequestMethod('GET');
$request->setQuery(new http\QueryString([
  'q' => ''
]));

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q=' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q=' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/assistant/agent_configurations/search?q=")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search"

querystring = {"q":""}

response = requests.get(url, params=querystring)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search"

queryString <- list(q = "")

response <- VERB("GET", url, query = queryString, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q=")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/assistant/agent_configurations/search') do |req|
  req.params['q'] = ''
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search";

    let querystring = [
        ("q", ""),
    ];

    let client = reqwest::Client::new();
    let response = client.get(url)
        .query(&querystring)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q='
http GET '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q='
wget --quiet \
  --method GET \
  --output-document \
  - '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q='
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/search?q=")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
PATCH Update agent configuration
{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId
QUERY PARAMS

wId
sId
BODY json

{
  "userFavorite": false
}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "PATCH");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n  \"userFavorite\": false\n}");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/patch "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId" {:content-type :json
                                                                                               :form-params {:userFavorite false}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId"
headers = HTTP::Headers{
  "content-type" => "application/json"
}
reqBody = "{\n  \"userFavorite\": false\n}"

response = HTTP::Client.patch url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Patch,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId"),
    Content = new StringContent("{\n  \"userFavorite\": false\n}")
    {
        Headers =
        {
            ContentType = new MediaTypeHeaderValue("application/json")
        }
    }
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId");
var request = new RestRequest("", Method.Patch);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n  \"userFavorite\": false\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId"

	payload := strings.NewReader("{\n  \"userFavorite\": false\n}")

	req, _ := http.NewRequest("PATCH", url, payload)

	req.Header.Add("content-type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
PATCH /baseUrl/api/v1/w/:wId/assistant/agent_configurations/:sId HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 27

{
  "userFavorite": false
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("PATCH", "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId")
  .setHeader("content-type", "application/json")
  .setBody("{\n  \"userFavorite\": false\n}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId"))
    .header("content-type", "application/json")
    .method("PATCH", HttpRequest.BodyPublishers.ofString("{\n  \"userFavorite\": false\n}"))
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n  \"userFavorite\": false\n}");
Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId")
  .patch(body)
  .addHeader("content-type", "application/json")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.patch("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId")
  .header("content-type", "application/json")
  .body("{\n  \"userFavorite\": false\n}")
  .asString();
const data = JSON.stringify({
  userFavorite: false
});

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('PATCH', '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId');
xhr.setRequestHeader('content-type', 'application/json');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'PATCH',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId',
  headers: {'content-type': 'application/json'},
  data: {userFavorite: false}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId';
const options = {
  method: 'PATCH',
  headers: {'content-type': 'application/json'},
  body: '{"userFavorite":false}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId',
  method: 'PATCH',
  headers: {
    'content-type': 'application/json'
  },
  processData: false,
  data: '{\n  "userFavorite": false\n}'
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n  \"userFavorite\": false\n}")
val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId")
  .patch(body)
  .addHeader("content-type", "application/json")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'PATCH',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/assistant/agent_configurations/:sId',
  headers: {
    'content-type': 'application/json'
  }
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.write(JSON.stringify({userFavorite: false}));
req.end();
const request = require('request');

const options = {
  method: 'PATCH',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId',
  headers: {'content-type': 'application/json'},
  body: {userFavorite: false},
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('PATCH', '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId');

req.headers({
  'content-type': 'application/json'
});

req.type('json');
req.send({
  userFavorite: false
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'PATCH',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId',
  headers: {'content-type': 'application/json'},
  data: {userFavorite: false}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId';
const options = {
  method: 'PATCH',
  headers: {'content-type': 'application/json'},
  body: '{"userFavorite":false}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"userFavorite": @NO };

NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"PATCH"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n  \"userFavorite\": false\n}" in

Client.call ~headers ~body `PATCH uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "PATCH",
  CURLOPT_POSTFIELDS => json_encode([
    'userFavorite' => null
  ]),
  CURLOPT_HTTPHEADER => [
    "content-type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('PATCH', '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId', [
  'body' => '{
  "userFavorite": false
}',
  'headers' => [
    'content-type' => 'application/json',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId');
$request->setMethod(HttpRequest::HTTP_METH_PATCH);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$request->setContentType('application/json');
$request->setBody(json_encode([
  'userFavorite' => null
]));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
append(json_encode([
  'userFavorite' => null
]));
$request->setRequestUrl('{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId');
$request->setRequestMethod('PATCH');
$request->setBody($body);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId' -Method PATCH -Headers $headers -ContentType 'application/json' -Body '{
  "userFavorite": false
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId' -Method PATCH -Headers $headers -ContentType 'application/json' -Body '{
  "userFavorite": false
}'
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = "{\n  \"userFavorite\": false\n}"

headers = { 'content-type': "application/json" }

conn.request("PATCH", "/baseUrl/api/v1/w/:wId/assistant/agent_configurations/:sId", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId"

payload = { "userFavorite": False }
headers = {"content-type": "application/json"}

response = requests.patch(url, json=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId"

payload <- "{\n  \"userFavorite\": false\n}"

encode <- "json"

response <- VERB("PATCH", url, body = payload, content_type("application/json"), encode = encode)

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Patch.new(url)
request["content-type"] = 'application/json'
request.body = "{\n  \"userFavorite\": false\n}"

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/json'}
)

response = conn.patch('/baseUrl/api/v1/w/:wId/assistant/agent_configurations/:sId') do |req|
  req.body = "{\n  \"userFavorite\": false\n}"
end

puts response.status
puts response.body
use std::str::FromStr;
use serde_json::json;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId";

    let payload = json!({"userFavorite": false});

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("content-type", "application/json".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.request(reqwest::Method::from_str("PATCH").unwrap(), url)
        .headers(headers)
        .json(&payload)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request PATCH \
  --url {{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId \
  --header 'content-type: application/json' \
  --data '{
  "userFavorite": false
}'
echo '{
  "userFavorite": false
}' |  \
  http PATCH {{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId \
  content-type:application/json
wget --quiet \
  --method PATCH \
  --header 'content-type: application/json' \
  --body-data '{\n  "userFavorite": false\n}' \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId
import Foundation

let headers = ["content-type": "application/json"]
let parameters = ["userFavorite": false] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/assistant/agent_configurations/:sId")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "PATCH"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "agentConfiguration": {
    "id": 12345,
    "sId": "7f3a9c2b1e",
    "version": 2,
    "versionCreatedAt": "2023-06-15T14:30:00Z",
    "versionAuthorId": "0ec9852c2f",
    "name": "Customer Support Agent",
    "description": "An AI agent designed to handle customer support inquiries",
    "instructions": "Always greet the customer politely and try to resolve their issue efficiently.",
    "pictureUrl": "https://example.com/agent-images/support-agent.png",
    "status": "active",
    "scope": "workspace",
    "userFavorite": true,
    "actions": [],
    "maxStepsPerRun": 10,
    "templateId": "b4e2f1a9c7"
  }
}
POST Create an app run
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs
QUERY PARAMS

wId
spaceId
aId
BODY json

{
  "specification_hash": "",
  "config": {
    "model": {
      "provider_id": "",
      "model_id": "",
      "use_cache": false,
      "use_stream": false
    }
  },
  "inputs": [
    {}
  ],
  "stream": false,
  "blocking": false,
  "block_filter": []
}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n  \"specification_hash\": \"\",\n  \"config\": {\n    \"model\": {\n      \"provider_id\": \"\",\n      \"model_id\": \"\",\n      \"use_cache\": false,\n      \"use_stream\": false\n    }\n  },\n  \"inputs\": [\n    {}\n  ],\n  \"stream\": false,\n  \"blocking\": false,\n  \"block_filter\": []\n}");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/post "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs" {:content-type :json
                                                                                         :form-params {:specification_hash ""
                                                                                                       :config {:model {:provider_id ""
                                                                                                                        :model_id ""
                                                                                                                        :use_cache false
                                                                                                                        :use_stream false}}
                                                                                                       :inputs [{}]
                                                                                                       :stream false
                                                                                                       :blocking false
                                                                                                       :block_filter []}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs"
headers = HTTP::Headers{
  "content-type" => "application/json"
}
reqBody = "{\n  \"specification_hash\": \"\",\n  \"config\": {\n    \"model\": {\n      \"provider_id\": \"\",\n      \"model_id\": \"\",\n      \"use_cache\": false,\n      \"use_stream\": false\n    }\n  },\n  \"inputs\": [\n    {}\n  ],\n  \"stream\": false,\n  \"blocking\": false,\n  \"block_filter\": []\n}"

response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Post,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs"),
    Content = new StringContent("{\n  \"specification_hash\": \"\",\n  \"config\": {\n    \"model\": {\n      \"provider_id\": \"\",\n      \"model_id\": \"\",\n      \"use_cache\": false,\n      \"use_stream\": false\n    }\n  },\n  \"inputs\": [\n    {}\n  ],\n  \"stream\": false,\n  \"blocking\": false,\n  \"block_filter\": []\n}")
    {
        Headers =
        {
            ContentType = new MediaTypeHeaderValue("application/json")
        }
    }
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n  \"specification_hash\": \"\",\n  \"config\": {\n    \"model\": {\n      \"provider_id\": \"\",\n      \"model_id\": \"\",\n      \"use_cache\": false,\n      \"use_stream\": false\n    }\n  },\n  \"inputs\": [\n    {}\n  ],\n  \"stream\": false,\n  \"blocking\": false,\n  \"block_filter\": []\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs"

	payload := strings.NewReader("{\n  \"specification_hash\": \"\",\n  \"config\": {\n    \"model\": {\n      \"provider_id\": \"\",\n      \"model_id\": \"\",\n      \"use_cache\": false,\n      \"use_stream\": false\n    }\n  },\n  \"inputs\": [\n    {}\n  ],\n  \"stream\": false,\n  \"blocking\": false,\n  \"block_filter\": []\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("content-type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
POST /baseUrl/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 257

{
  "specification_hash": "",
  "config": {
    "model": {
      "provider_id": "",
      "model_id": "",
      "use_cache": false,
      "use_stream": false
    }
  },
  "inputs": [
    {}
  ],
  "stream": false,
  "blocking": false,
  "block_filter": []
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs")
  .setHeader("content-type", "application/json")
  .setBody("{\n  \"specification_hash\": \"\",\n  \"config\": {\n    \"model\": {\n      \"provider_id\": \"\",\n      \"model_id\": \"\",\n      \"use_cache\": false,\n      \"use_stream\": false\n    }\n  },\n  \"inputs\": [\n    {}\n  ],\n  \"stream\": false,\n  \"blocking\": false,\n  \"block_filter\": []\n}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs"))
    .header("content-type", "application/json")
    .method("POST", HttpRequest.BodyPublishers.ofString("{\n  \"specification_hash\": \"\",\n  \"config\": {\n    \"model\": {\n      \"provider_id\": \"\",\n      \"model_id\": \"\",\n      \"use_cache\": false,\n      \"use_stream\": false\n    }\n  },\n  \"inputs\": [\n    {}\n  ],\n  \"stream\": false,\n  \"blocking\": false,\n  \"block_filter\": []\n}"))
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n  \"specification_hash\": \"\",\n  \"config\": {\n    \"model\": {\n      \"provider_id\": \"\",\n      \"model_id\": \"\",\n      \"use_cache\": false,\n      \"use_stream\": false\n    }\n  },\n  \"inputs\": [\n    {}\n  ],\n  \"stream\": false,\n  \"blocking\": false,\n  \"block_filter\": []\n}");
Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs")
  .post(body)
  .addHeader("content-type", "application/json")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs")
  .header("content-type", "application/json")
  .body("{\n  \"specification_hash\": \"\",\n  \"config\": {\n    \"model\": {\n      \"provider_id\": \"\",\n      \"model_id\": \"\",\n      \"use_cache\": false,\n      \"use_stream\": false\n    }\n  },\n  \"inputs\": [\n    {}\n  ],\n  \"stream\": false,\n  \"blocking\": false,\n  \"block_filter\": []\n}")
  .asString();
const data = JSON.stringify({
  specification_hash: '',
  config: {
    model: {
      provider_id: '',
      model_id: '',
      use_cache: false,
      use_stream: false
    }
  },
  inputs: [
    {}
  ],
  stream: false,
  blocking: false,
  block_filter: []
});

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('POST', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs');
xhr.setRequestHeader('content-type', 'application/json');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs',
  headers: {'content-type': 'application/json'},
  data: {
    specification_hash: '',
    config: {model: {provider_id: '', model_id: '', use_cache: false, use_stream: false}},
    inputs: [{}],
    stream: false,
    blocking: false,
    block_filter: []
  }
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"specification_hash":"","config":{"model":{"provider_id":"","model_id":"","use_cache":false,"use_stream":false}},"inputs":[{}],"stream":false,"blocking":false,"block_filter":[]}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs',
  method: 'POST',
  headers: {
    'content-type': 'application/json'
  },
  processData: false,
  data: '{\n  "specification_hash": "",\n  "config": {\n    "model": {\n      "provider_id": "",\n      "model_id": "",\n      "use_cache": false,\n      "use_stream": false\n    }\n  },\n  "inputs": [\n    {}\n  ],\n  "stream": false,\n  "blocking": false,\n  "block_filter": []\n}'
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n  \"specification_hash\": \"\",\n  \"config\": {\n    \"model\": {\n      \"provider_id\": \"\",\n      \"model_id\": \"\",\n      \"use_cache\": false,\n      \"use_stream\": false\n    }\n  },\n  \"inputs\": [\n    {}\n  ],\n  \"stream\": false,\n  \"blocking\": false,\n  \"block_filter\": []\n}")
val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs")
  .post(body)
  .addHeader("content-type", "application/json")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'POST',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs',
  headers: {
    'content-type': 'application/json'
  }
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.write(JSON.stringify({
  specification_hash: '',
  config: {model: {provider_id: '', model_id: '', use_cache: false, use_stream: false}},
  inputs: [{}],
  stream: false,
  blocking: false,
  block_filter: []
}));
req.end();
const request = require('request');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs',
  headers: {'content-type': 'application/json'},
  body: {
    specification_hash: '',
    config: {model: {provider_id: '', model_id: '', use_cache: false, use_stream: false}},
    inputs: [{}],
    stream: false,
    blocking: false,
    block_filter: []
  },
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('POST', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs');

req.headers({
  'content-type': 'application/json'
});

req.type('json');
req.send({
  specification_hash: '',
  config: {
    model: {
      provider_id: '',
      model_id: '',
      use_cache: false,
      use_stream: false
    }
  },
  inputs: [
    {}
  ],
  stream: false,
  blocking: false,
  block_filter: []
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs',
  headers: {'content-type': 'application/json'},
  data: {
    specification_hash: '',
    config: {model: {provider_id: '', model_id: '', use_cache: false, use_stream: false}},
    inputs: [{}],
    stream: false,
    blocking: false,
    block_filter: []
  }
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"specification_hash":"","config":{"model":{"provider_id":"","model_id":"","use_cache":false,"use_stream":false}},"inputs":[{}],"stream":false,"blocking":false,"block_filter":[]}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"specification_hash": @"",
                              @"config": @{ @"model": @{ @"provider_id": @"", @"model_id": @"", @"use_cache": @NO, @"use_stream": @NO } },
                              @"inputs": @[ @{  } ],
                              @"stream": @NO,
                              @"blocking": @NO,
                              @"block_filter": @[  ] };

NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n  \"specification_hash\": \"\",\n  \"config\": {\n    \"model\": {\n      \"provider_id\": \"\",\n      \"model_id\": \"\",\n      \"use_cache\": false,\n      \"use_stream\": false\n    }\n  },\n  \"inputs\": [\n    {}\n  ],\n  \"stream\": false,\n  \"blocking\": false,\n  \"block_filter\": []\n}" in

Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => json_encode([
    'specification_hash' => '',
    'config' => [
        'model' => [
                'provider_id' => '',
                'model_id' => '',
                'use_cache' => null,
                'use_stream' => null
        ]
    ],
    'inputs' => [
        [
                
        ]
    ],
    'stream' => null,
    'blocking' => null,
    'block_filter' => [
        
    ]
  ]),
  CURLOPT_HTTPHEADER => [
    "content-type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('POST', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs', [
  'body' => '{
  "specification_hash": "",
  "config": {
    "model": {
      "provider_id": "",
      "model_id": "",
      "use_cache": false,
      "use_stream": false
    }
  },
  "inputs": [
    {}
  ],
  "stream": false,
  "blocking": false,
  "block_filter": []
}',
  'headers' => [
    'content-type' => 'application/json',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$request->setContentType('application/json');
$request->setBody(json_encode([
  'specification_hash' => '',
  'config' => [
    'model' => [
        'provider_id' => '',
        'model_id' => '',
        'use_cache' => null,
        'use_stream' => null
    ]
  ],
  'inputs' => [
    [
        
    ]
  ],
  'stream' => null,
  'blocking' => null,
  'block_filter' => [
    
  ]
]));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
append(json_encode([
  'specification_hash' => '',
  'config' => [
    'model' => [
        'provider_id' => '',
        'model_id' => '',
        'use_cache' => null,
        'use_stream' => null
    ]
  ],
  'inputs' => [
    [
        
    ]
  ],
  'stream' => null,
  'blocking' => null,
  'block_filter' => [
    
  ]
]));
$request->setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs');
$request->setRequestMethod('POST');
$request->setBody($body);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "specification_hash": "",
  "config": {
    "model": {
      "provider_id": "",
      "model_id": "",
      "use_cache": false,
      "use_stream": false
    }
  },
  "inputs": [
    {}
  ],
  "stream": false,
  "blocking": false,
  "block_filter": []
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "specification_hash": "",
  "config": {
    "model": {
      "provider_id": "",
      "model_id": "",
      "use_cache": false,
      "use_stream": false
    }
  },
  "inputs": [
    {}
  ],
  "stream": false,
  "blocking": false,
  "block_filter": []
}'
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = "{\n  \"specification_hash\": \"\",\n  \"config\": {\n    \"model\": {\n      \"provider_id\": \"\",\n      \"model_id\": \"\",\n      \"use_cache\": false,\n      \"use_stream\": false\n    }\n  },\n  \"inputs\": [\n    {}\n  ],\n  \"stream\": false,\n  \"blocking\": false,\n  \"block_filter\": []\n}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs"

payload = {
    "specification_hash": "",
    "config": { "model": {
            "provider_id": "",
            "model_id": "",
            "use_cache": False,
            "use_stream": False
        } },
    "inputs": [{}],
    "stream": False,
    "blocking": False,
    "block_filter": []
}
headers = {"content-type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs"

payload <- "{\n  \"specification_hash\": \"\",\n  \"config\": {\n    \"model\": {\n      \"provider_id\": \"\",\n      \"model_id\": \"\",\n      \"use_cache\": false,\n      \"use_stream\": false\n    }\n  },\n  \"inputs\": [\n    {}\n  ],\n  \"stream\": false,\n  \"blocking\": false,\n  \"block_filter\": []\n}"

encode <- "json"

response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\n  \"specification_hash\": \"\",\n  \"config\": {\n    \"model\": {\n      \"provider_id\": \"\",\n      \"model_id\": \"\",\n      \"use_cache\": false,\n      \"use_stream\": false\n    }\n  },\n  \"inputs\": [\n    {}\n  ],\n  \"stream\": false,\n  \"blocking\": false,\n  \"block_filter\": []\n}"

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/json'}
)

response = conn.post('/baseUrl/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs') do |req|
  req.body = "{\n  \"specification_hash\": \"\",\n  \"config\": {\n    \"model\": {\n      \"provider_id\": \"\",\n      \"model_id\": \"\",\n      \"use_cache\": false,\n      \"use_stream\": false\n    }\n  },\n  \"inputs\": [\n    {}\n  ],\n  \"stream\": false,\n  \"blocking\": false,\n  \"block_filter\": []\n}"
end

puts response.status
puts response.body
use serde_json::json;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs";

    let payload = json!({
        "specification_hash": "",
        "config": json!({"model": json!({
                "provider_id": "",
                "model_id": "",
                "use_cache": false,
                "use_stream": false
            })}),
        "inputs": (json!({})),
        "stream": false,
        "blocking": false,
        "block_filter": ()
    });

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("content-type", "application/json".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.post(url)
        .headers(headers)
        .json(&payload)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request POST \
  --url {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs \
  --header 'content-type: application/json' \
  --data '{
  "specification_hash": "",
  "config": {
    "model": {
      "provider_id": "",
      "model_id": "",
      "use_cache": false,
      "use_stream": false
    }
  },
  "inputs": [
    {}
  ],
  "stream": false,
  "blocking": false,
  "block_filter": []
}'
echo '{
  "specification_hash": "",
  "config": {
    "model": {
      "provider_id": "",
      "model_id": "",
      "use_cache": false,
      "use_stream": false
    }
  },
  "inputs": [
    {}
  ],
  "stream": false,
  "blocking": false,
  "block_filter": []
}' |  \
  http POST {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs \
  content-type:application/json
wget --quiet \
  --method POST \
  --header 'content-type: application/json' \
  --body-data '{\n  "specification_hash": "",\n  "config": {\n    "model": {\n      "provider_id": "",\n      "model_id": "",\n      "use_cache": false,\n      "use_stream": false\n    }\n  },\n  "inputs": [\n    {}\n  ],\n  "stream": false,\n  "blocking": false,\n  "block_filter": []\n}' \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs
import Foundation

let headers = ["content-type": "application/json"]
let parameters = [
  "specification_hash": "",
  "config": ["model": [
      "provider_id": "",
      "model_id": "",
      "use_cache": false,
      "use_stream": false
    ]],
  "inputs": [[]],
  "stream": false,
  "blocking": false,
  "block_filter": []
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "run": {
    "run_id": "4a2c6e8b0d",
    "app_id": "9f1d3b5a7c",
    "results": {},
    "specification_hash": "8c0a4e6d2f"
  }
}
GET Get an app run
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId
QUERY PARAMS

wId
spaceId
aId
runId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId"

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId"))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId');
$request->setMethod(HTTP_METH_GET);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId"

response = requests.get(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId"

response <- VERB("GET", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId') do |req|
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId";

    let client = reqwest::Client::new();
    let response = client.get(url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId
http GET {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId
wget --quiet \
  --method GET \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps/:aId/runs/:runId")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "run": {
    "run_id": "4a2c6e8b0d",
    "app_id": "9f1d3b5a7c",
    "results": {},
    "specification_hash": "8c0a4e6d2f"
  }
}
GET List apps
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps
QUERY PARAMS

wId
spaceId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps"

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/spaces/:spaceId/apps HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps"))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/apps',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps');
$request->setMethod(HTTP_METH_GET);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/apps")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps"

response = requests.get(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps"

response <- VERB("GET", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/spaces/:spaceId/apps') do |req|
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps";

    let client = reqwest::Client::new();
    let response = client.get(url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps
http GET {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps
wget --quiet \
  --method GET \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/apps")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
POST Cancel message generation in a conversation
{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel
QUERY PARAMS

wId
cId
BODY json

{
  "messageIds": []
}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n  \"messageIds\": []\n}");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/post "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel" {:content-type :json
                                                                                              :form-params {:messageIds []}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel"
headers = HTTP::Headers{
  "content-type" => "application/json"
}
reqBody = "{\n  \"messageIds\": []\n}"

response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Post,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel"),
    Content = new StringContent("{\n  \"messageIds\": []\n}")
    {
        Headers =
        {
            ContentType = new MediaTypeHeaderValue("application/json")
        }
    }
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n  \"messageIds\": []\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel"

	payload := strings.NewReader("{\n  \"messageIds\": []\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("content-type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
POST /baseUrl/api/v1/w/:wId/assistant/conversations/:cId/cancel HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 22

{
  "messageIds": []
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel")
  .setHeader("content-type", "application/json")
  .setBody("{\n  \"messageIds\": []\n}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel"))
    .header("content-type", "application/json")
    .method("POST", HttpRequest.BodyPublishers.ofString("{\n  \"messageIds\": []\n}"))
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n  \"messageIds\": []\n}");
Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel")
  .post(body)
  .addHeader("content-type", "application/json")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel")
  .header("content-type", "application/json")
  .body("{\n  \"messageIds\": []\n}")
  .asString();
const data = JSON.stringify({
  messageIds: []
});

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('POST', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel');
xhr.setRequestHeader('content-type', 'application/json');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel',
  headers: {'content-type': 'application/json'},
  data: {messageIds: []}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"messageIds":[]}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel',
  method: 'POST',
  headers: {
    'content-type': 'application/json'
  },
  processData: false,
  data: '{\n  "messageIds": []\n}'
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n  \"messageIds\": []\n}")
val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel")
  .post(body)
  .addHeader("content-type", "application/json")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'POST',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/cancel',
  headers: {
    'content-type': 'application/json'
  }
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.write(JSON.stringify({messageIds: []}));
req.end();
const request = require('request');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel',
  headers: {'content-type': 'application/json'},
  body: {messageIds: []},
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('POST', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel');

req.headers({
  'content-type': 'application/json'
});

req.type('json');
req.send({
  messageIds: []
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel',
  headers: {'content-type': 'application/json'},
  data: {messageIds: []}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"messageIds":[]}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"messageIds": @[  ] };

NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n  \"messageIds\": []\n}" in

Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => json_encode([
    'messageIds' => [
        
    ]
  ]),
  CURLOPT_HTTPHEADER => [
    "content-type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('POST', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel', [
  'body' => '{
  "messageIds": []
}',
  'headers' => [
    'content-type' => 'application/json',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$request->setContentType('application/json');
$request->setBody(json_encode([
  'messageIds' => [
    
  ]
]));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
append(json_encode([
  'messageIds' => [
    
  ]
]));
$request->setRequestUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel');
$request->setRequestMethod('POST');
$request->setBody($body);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "messageIds": []
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "messageIds": []
}'
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = "{\n  \"messageIds\": []\n}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/cancel", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel"

payload = { "messageIds": [] }
headers = {"content-type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel"

payload <- "{\n  \"messageIds\": []\n}"

encode <- "json"

response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\n  \"messageIds\": []\n}"

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/json'}
)

response = conn.post('/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/cancel') do |req|
  req.body = "{\n  \"messageIds\": []\n}"
end

puts response.status
puts response.body
use serde_json::json;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel";

    let payload = json!({"messageIds": ()});

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("content-type", "application/json".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.post(url)
        .headers(headers)
        .json(&payload)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request POST \
  --url {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel \
  --header 'content-type: application/json' \
  --data '{
  "messageIds": []
}'
echo '{
  "messageIds": []
}' |  \
  http POST {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel \
  content-type:application/json
wget --quiet \
  --method POST \
  --header 'content-type: application/json' \
  --body-data '{\n  "messageIds": []\n}' \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel
import Foundation

let headers = ["content-type": "application/json"]
let parameters = ["messageIds": []] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/cancel")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
POST Create a content fragment
{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments
QUERY PARAMS

wId
cId
BODY json

{
  "title": "",
  "content": "",
  "contentType": "",
  "url": "",
  "fileId": "",
  "nodeId": "",
  "nodeDataSourceViewId": "",
  "context": {
    "username": "",
    "timezone": "",
    "fullName": "",
    "email": "",
    "profilePictureUrl": "",
    "origin": ""
  }
}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n  \"title\": \"\",\n  \"content\": \"\",\n  \"contentType\": \"\",\n  \"url\": \"\",\n  \"fileId\": \"\",\n  \"nodeId\": \"\",\n  \"nodeDataSourceViewId\": \"\",\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/post "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments" {:content-type :json
                                                                                                         :form-params {:title ""
                                                                                                                       :content ""
                                                                                                                       :contentType ""
                                                                                                                       :url ""
                                                                                                                       :fileId ""
                                                                                                                       :nodeId ""
                                                                                                                       :nodeDataSourceViewId ""
                                                                                                                       :context {:username ""
                                                                                                                                 :timezone ""
                                                                                                                                 :fullName ""
                                                                                                                                 :email ""
                                                                                                                                 :profilePictureUrl ""
                                                                                                                                 :origin ""}}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments"
headers = HTTP::Headers{
  "content-type" => "application/json"
}
reqBody = "{\n  \"title\": \"\",\n  \"content\": \"\",\n  \"contentType\": \"\",\n  \"url\": \"\",\n  \"fileId\": \"\",\n  \"nodeId\": \"\",\n  \"nodeDataSourceViewId\": \"\",\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}"

response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Post,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments"),
    Content = new StringContent("{\n  \"title\": \"\",\n  \"content\": \"\",\n  \"contentType\": \"\",\n  \"url\": \"\",\n  \"fileId\": \"\",\n  \"nodeId\": \"\",\n  \"nodeDataSourceViewId\": \"\",\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}")
    {
        Headers =
        {
            ContentType = new MediaTypeHeaderValue("application/json")
        }
    }
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n  \"title\": \"\",\n  \"content\": \"\",\n  \"contentType\": \"\",\n  \"url\": \"\",\n  \"fileId\": \"\",\n  \"nodeId\": \"\",\n  \"nodeDataSourceViewId\": \"\",\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments"

	payload := strings.NewReader("{\n  \"title\": \"\",\n  \"content\": \"\",\n  \"contentType\": \"\",\n  \"url\": \"\",\n  \"fileId\": \"\",\n  \"nodeId\": \"\",\n  \"nodeDataSourceViewId\": \"\",\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("content-type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
POST /baseUrl/api/v1/w/:wId/assistant/conversations/:cId/content_fragments HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 273

{
  "title": "",
  "content": "",
  "contentType": "",
  "url": "",
  "fileId": "",
  "nodeId": "",
  "nodeDataSourceViewId": "",
  "context": {
    "username": "",
    "timezone": "",
    "fullName": "",
    "email": "",
    "profilePictureUrl": "",
    "origin": ""
  }
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments")
  .setHeader("content-type", "application/json")
  .setBody("{\n  \"title\": \"\",\n  \"content\": \"\",\n  \"contentType\": \"\",\n  \"url\": \"\",\n  \"fileId\": \"\",\n  \"nodeId\": \"\",\n  \"nodeDataSourceViewId\": \"\",\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments"))
    .header("content-type", "application/json")
    .method("POST", HttpRequest.BodyPublishers.ofString("{\n  \"title\": \"\",\n  \"content\": \"\",\n  \"contentType\": \"\",\n  \"url\": \"\",\n  \"fileId\": \"\",\n  \"nodeId\": \"\",\n  \"nodeDataSourceViewId\": \"\",\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}"))
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n  \"title\": \"\",\n  \"content\": \"\",\n  \"contentType\": \"\",\n  \"url\": \"\",\n  \"fileId\": \"\",\n  \"nodeId\": \"\",\n  \"nodeDataSourceViewId\": \"\",\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}");
Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments")
  .post(body)
  .addHeader("content-type", "application/json")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments")
  .header("content-type", "application/json")
  .body("{\n  \"title\": \"\",\n  \"content\": \"\",\n  \"contentType\": \"\",\n  \"url\": \"\",\n  \"fileId\": \"\",\n  \"nodeId\": \"\",\n  \"nodeDataSourceViewId\": \"\",\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}")
  .asString();
const data = JSON.stringify({
  title: '',
  content: '',
  contentType: '',
  url: '',
  fileId: '',
  nodeId: '',
  nodeDataSourceViewId: '',
  context: {
    username: '',
    timezone: '',
    fullName: '',
    email: '',
    profilePictureUrl: '',
    origin: ''
  }
});

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('POST', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments');
xhr.setRequestHeader('content-type', 'application/json');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments',
  headers: {'content-type': 'application/json'},
  data: {
    title: '',
    content: '',
    contentType: '',
    url: '',
    fileId: '',
    nodeId: '',
    nodeDataSourceViewId: '',
    context: {
      username: '',
      timezone: '',
      fullName: '',
      email: '',
      profilePictureUrl: '',
      origin: ''
    }
  }
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"title":"","content":"","contentType":"","url":"","fileId":"","nodeId":"","nodeDataSourceViewId":"","context":{"username":"","timezone":"","fullName":"","email":"","profilePictureUrl":"","origin":""}}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments',
  method: 'POST',
  headers: {
    'content-type': 'application/json'
  },
  processData: false,
  data: '{\n  "title": "",\n  "content": "",\n  "contentType": "",\n  "url": "",\n  "fileId": "",\n  "nodeId": "",\n  "nodeDataSourceViewId": "",\n  "context": {\n    "username": "",\n    "timezone": "",\n    "fullName": "",\n    "email": "",\n    "profilePictureUrl": "",\n    "origin": ""\n  }\n}'
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n  \"title\": \"\",\n  \"content\": \"\",\n  \"contentType\": \"\",\n  \"url\": \"\",\n  \"fileId\": \"\",\n  \"nodeId\": \"\",\n  \"nodeDataSourceViewId\": \"\",\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}")
val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments")
  .post(body)
  .addHeader("content-type", "application/json")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'POST',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/content_fragments',
  headers: {
    'content-type': 'application/json'
  }
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.write(JSON.stringify({
  title: '',
  content: '',
  contentType: '',
  url: '',
  fileId: '',
  nodeId: '',
  nodeDataSourceViewId: '',
  context: {
    username: '',
    timezone: '',
    fullName: '',
    email: '',
    profilePictureUrl: '',
    origin: ''
  }
}));
req.end();
const request = require('request');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments',
  headers: {'content-type': 'application/json'},
  body: {
    title: '',
    content: '',
    contentType: '',
    url: '',
    fileId: '',
    nodeId: '',
    nodeDataSourceViewId: '',
    context: {
      username: '',
      timezone: '',
      fullName: '',
      email: '',
      profilePictureUrl: '',
      origin: ''
    }
  },
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('POST', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments');

req.headers({
  'content-type': 'application/json'
});

req.type('json');
req.send({
  title: '',
  content: '',
  contentType: '',
  url: '',
  fileId: '',
  nodeId: '',
  nodeDataSourceViewId: '',
  context: {
    username: '',
    timezone: '',
    fullName: '',
    email: '',
    profilePictureUrl: '',
    origin: ''
  }
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments',
  headers: {'content-type': 'application/json'},
  data: {
    title: '',
    content: '',
    contentType: '',
    url: '',
    fileId: '',
    nodeId: '',
    nodeDataSourceViewId: '',
    context: {
      username: '',
      timezone: '',
      fullName: '',
      email: '',
      profilePictureUrl: '',
      origin: ''
    }
  }
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"title":"","content":"","contentType":"","url":"","fileId":"","nodeId":"","nodeDataSourceViewId":"","context":{"username":"","timezone":"","fullName":"","email":"","profilePictureUrl":"","origin":""}}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"title": @"",
                              @"content": @"",
                              @"contentType": @"",
                              @"url": @"",
                              @"fileId": @"",
                              @"nodeId": @"",
                              @"nodeDataSourceViewId": @"",
                              @"context": @{ @"username": @"", @"timezone": @"", @"fullName": @"", @"email": @"", @"profilePictureUrl": @"", @"origin": @"" } };

NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n  \"title\": \"\",\n  \"content\": \"\",\n  \"contentType\": \"\",\n  \"url\": \"\",\n  \"fileId\": \"\",\n  \"nodeId\": \"\",\n  \"nodeDataSourceViewId\": \"\",\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}" in

Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => json_encode([
    'title' => '',
    'content' => '',
    'contentType' => '',
    'url' => '',
    'fileId' => '',
    'nodeId' => '',
    'nodeDataSourceViewId' => '',
    'context' => [
        'username' => '',
        'timezone' => '',
        'fullName' => '',
        'email' => '',
        'profilePictureUrl' => '',
        'origin' => ''
    ]
  ]),
  CURLOPT_HTTPHEADER => [
    "content-type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('POST', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments', [
  'body' => '{
  "title": "",
  "content": "",
  "contentType": "",
  "url": "",
  "fileId": "",
  "nodeId": "",
  "nodeDataSourceViewId": "",
  "context": {
    "username": "",
    "timezone": "",
    "fullName": "",
    "email": "",
    "profilePictureUrl": "",
    "origin": ""
  }
}',
  'headers' => [
    'content-type' => 'application/json',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$request->setContentType('application/json');
$request->setBody(json_encode([
  'title' => '',
  'content' => '',
  'contentType' => '',
  'url' => '',
  'fileId' => '',
  'nodeId' => '',
  'nodeDataSourceViewId' => '',
  'context' => [
    'username' => '',
    'timezone' => '',
    'fullName' => '',
    'email' => '',
    'profilePictureUrl' => '',
    'origin' => ''
  ]
]));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
append(json_encode([
  'title' => '',
  'content' => '',
  'contentType' => '',
  'url' => '',
  'fileId' => '',
  'nodeId' => '',
  'nodeDataSourceViewId' => '',
  'context' => [
    'username' => '',
    'timezone' => '',
    'fullName' => '',
    'email' => '',
    'profilePictureUrl' => '',
    'origin' => ''
  ]
]));
$request->setRequestUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments');
$request->setRequestMethod('POST');
$request->setBody($body);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "title": "",
  "content": "",
  "contentType": "",
  "url": "",
  "fileId": "",
  "nodeId": "",
  "nodeDataSourceViewId": "",
  "context": {
    "username": "",
    "timezone": "",
    "fullName": "",
    "email": "",
    "profilePictureUrl": "",
    "origin": ""
  }
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "title": "",
  "content": "",
  "contentType": "",
  "url": "",
  "fileId": "",
  "nodeId": "",
  "nodeDataSourceViewId": "",
  "context": {
    "username": "",
    "timezone": "",
    "fullName": "",
    "email": "",
    "profilePictureUrl": "",
    "origin": ""
  }
}'
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = "{\n  \"title\": \"\",\n  \"content\": \"\",\n  \"contentType\": \"\",\n  \"url\": \"\",\n  \"fileId\": \"\",\n  \"nodeId\": \"\",\n  \"nodeDataSourceViewId\": \"\",\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/content_fragments", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments"

payload = {
    "title": "",
    "content": "",
    "contentType": "",
    "url": "",
    "fileId": "",
    "nodeId": "",
    "nodeDataSourceViewId": "",
    "context": {
        "username": "",
        "timezone": "",
        "fullName": "",
        "email": "",
        "profilePictureUrl": "",
        "origin": ""
    }
}
headers = {"content-type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments"

payload <- "{\n  \"title\": \"\",\n  \"content\": \"\",\n  \"contentType\": \"\",\n  \"url\": \"\",\n  \"fileId\": \"\",\n  \"nodeId\": \"\",\n  \"nodeDataSourceViewId\": \"\",\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}"

encode <- "json"

response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\n  \"title\": \"\",\n  \"content\": \"\",\n  \"contentType\": \"\",\n  \"url\": \"\",\n  \"fileId\": \"\",\n  \"nodeId\": \"\",\n  \"nodeDataSourceViewId\": \"\",\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}"

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/json'}
)

response = conn.post('/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/content_fragments') do |req|
  req.body = "{\n  \"title\": \"\",\n  \"content\": \"\",\n  \"contentType\": \"\",\n  \"url\": \"\",\n  \"fileId\": \"\",\n  \"nodeId\": \"\",\n  \"nodeDataSourceViewId\": \"\",\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}"
end

puts response.status
puts response.body
use serde_json::json;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments";

    let payload = json!({
        "title": "",
        "content": "",
        "contentType": "",
        "url": "",
        "fileId": "",
        "nodeId": "",
        "nodeDataSourceViewId": "",
        "context": json!({
            "username": "",
            "timezone": "",
            "fullName": "",
            "email": "",
            "profilePictureUrl": "",
            "origin": ""
        })
    });

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("content-type", "application/json".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.post(url)
        .headers(headers)
        .json(&payload)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request POST \
  --url {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments \
  --header 'content-type: application/json' \
  --data '{
  "title": "",
  "content": "",
  "contentType": "",
  "url": "",
  "fileId": "",
  "nodeId": "",
  "nodeDataSourceViewId": "",
  "context": {
    "username": "",
    "timezone": "",
    "fullName": "",
    "email": "",
    "profilePictureUrl": "",
    "origin": ""
  }
}'
echo '{
  "title": "",
  "content": "",
  "contentType": "",
  "url": "",
  "fileId": "",
  "nodeId": "",
  "nodeDataSourceViewId": "",
  "context": {
    "username": "",
    "timezone": "",
    "fullName": "",
    "email": "",
    "profilePictureUrl": "",
    "origin": ""
  }
}' |  \
  http POST {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments \
  content-type:application/json
wget --quiet \
  --method POST \
  --header 'content-type: application/json' \
  --body-data '{\n  "title": "",\n  "content": "",\n  "contentType": "",\n  "url": "",\n  "fileId": "",\n  "nodeId": "",\n  "nodeDataSourceViewId": "",\n  "context": {\n    "username": "",\n    "timezone": "",\n    "fullName": "",\n    "email": "",\n    "profilePictureUrl": "",\n    "origin": ""\n  }\n}' \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments
import Foundation

let headers = ["content-type": "application/json"]
let parameters = [
  "title": "",
  "content": "",
  "contentType": "",
  "url": "",
  "fileId": "",
  "nodeId": "",
  "nodeDataSourceViewId": "",
  "context": [
    "username": "",
    "timezone": "",
    "fullName": "",
    "email": "",
    "profilePictureUrl": "",
    "origin": ""
  ]
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/content_fragments")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "title": "My content fragment",
  "content": "This is my content fragment extracted text",
  "contentType": "text/plain",
  "url": "https://example.com/content",
  "fileId": "fil_123456",
  "nodeId": "node_123456",
  "nodeDataSourceViewId": "dsv_123456",
  "context": {
    "username": "johndoe123",
    "timezone": "America/New_York",
    "fullName": "John Doe",
    "email": "john.doe@example.com",
    "profilePictureUrl": "https://example.com/profiles/johndoe123.jpg"
  }
}
POST Create a file upload URL
{{baseUrl}}/api/v1/w/:wId/files
QUERY PARAMS

wId
BODY json

{
  "contentType": "",
  "fileName": "",
  "fileSize": 0,
  "useCase": "",
  "useCaseMetadata": ""
}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/files");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n  \"contentType\": \"\",\n  \"fileName\": \"\",\n  \"fileSize\": 0,\n  \"useCase\": \"\",\n  \"useCaseMetadata\": \"\"\n}");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/post "{{baseUrl}}/api/v1/w/:wId/files" {:content-type :json
                                                                :form-params {:contentType ""
                                                                              :fileName ""
                                                                              :fileSize 0
                                                                              :useCase ""
                                                                              :useCaseMetadata ""}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/files"
headers = HTTP::Headers{
  "content-type" => "application/json"
}
reqBody = "{\n  \"contentType\": \"\",\n  \"fileName\": \"\",\n  \"fileSize\": 0,\n  \"useCase\": \"\",\n  \"useCaseMetadata\": \"\"\n}"

response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Post,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/files"),
    Content = new StringContent("{\n  \"contentType\": \"\",\n  \"fileName\": \"\",\n  \"fileSize\": 0,\n  \"useCase\": \"\",\n  \"useCaseMetadata\": \"\"\n}")
    {
        Headers =
        {
            ContentType = new MediaTypeHeaderValue("application/json")
        }
    }
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/files");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n  \"contentType\": \"\",\n  \"fileName\": \"\",\n  \"fileSize\": 0,\n  \"useCase\": \"\",\n  \"useCaseMetadata\": \"\"\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/files"

	payload := strings.NewReader("{\n  \"contentType\": \"\",\n  \"fileName\": \"\",\n  \"fileSize\": 0,\n  \"useCase\": \"\",\n  \"useCaseMetadata\": \"\"\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("content-type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
POST /baseUrl/api/v1/w/:wId/files HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 100

{
  "contentType": "",
  "fileName": "",
  "fileSize": 0,
  "useCase": "",
  "useCaseMetadata": ""
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/api/v1/w/:wId/files")
  .setHeader("content-type", "application/json")
  .setBody("{\n  \"contentType\": \"\",\n  \"fileName\": \"\",\n  \"fileSize\": 0,\n  \"useCase\": \"\",\n  \"useCaseMetadata\": \"\"\n}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/files"))
    .header("content-type", "application/json")
    .method("POST", HttpRequest.BodyPublishers.ofString("{\n  \"contentType\": \"\",\n  \"fileName\": \"\",\n  \"fileSize\": 0,\n  \"useCase\": \"\",\n  \"useCaseMetadata\": \"\"\n}"))
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n  \"contentType\": \"\",\n  \"fileName\": \"\",\n  \"fileSize\": 0,\n  \"useCase\": \"\",\n  \"useCaseMetadata\": \"\"\n}");
Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/files")
  .post(body)
  .addHeader("content-type", "application/json")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/api/v1/w/:wId/files")
  .header("content-type", "application/json")
  .body("{\n  \"contentType\": \"\",\n  \"fileName\": \"\",\n  \"fileSize\": 0,\n  \"useCase\": \"\",\n  \"useCaseMetadata\": \"\"\n}")
  .asString();
const data = JSON.stringify({
  contentType: '',
  fileName: '',
  fileSize: 0,
  useCase: '',
  useCaseMetadata: ''
});

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('POST', '{{baseUrl}}/api/v1/w/:wId/files');
xhr.setRequestHeader('content-type', 'application/json');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/files',
  headers: {'content-type': 'application/json'},
  data: {contentType: '', fileName: '', fileSize: 0, useCase: '', useCaseMetadata: ''}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/files';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"contentType":"","fileName":"","fileSize":0,"useCase":"","useCaseMetadata":""}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/files',
  method: 'POST',
  headers: {
    'content-type': 'application/json'
  },
  processData: false,
  data: '{\n  "contentType": "",\n  "fileName": "",\n  "fileSize": 0,\n  "useCase": "",\n  "useCaseMetadata": ""\n}'
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n  \"contentType\": \"\",\n  \"fileName\": \"\",\n  \"fileSize\": 0,\n  \"useCase\": \"\",\n  \"useCaseMetadata\": \"\"\n}")
val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/files")
  .post(body)
  .addHeader("content-type", "application/json")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'POST',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/files',
  headers: {
    'content-type': 'application/json'
  }
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.write(JSON.stringify({contentType: '', fileName: '', fileSize: 0, useCase: '', useCaseMetadata: ''}));
req.end();
const request = require('request');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/files',
  headers: {'content-type': 'application/json'},
  body: {contentType: '', fileName: '', fileSize: 0, useCase: '', useCaseMetadata: ''},
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('POST', '{{baseUrl}}/api/v1/w/:wId/files');

req.headers({
  'content-type': 'application/json'
});

req.type('json');
req.send({
  contentType: '',
  fileName: '',
  fileSize: 0,
  useCase: '',
  useCaseMetadata: ''
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/files',
  headers: {'content-type': 'application/json'},
  data: {contentType: '', fileName: '', fileSize: 0, useCase: '', useCaseMetadata: ''}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/files';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"contentType":"","fileName":"","fileSize":0,"useCase":"","useCaseMetadata":""}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"contentType": @"",
                              @"fileName": @"",
                              @"fileSize": @0,
                              @"useCase": @"",
                              @"useCaseMetadata": @"" };

NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/files"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/files" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n  \"contentType\": \"\",\n  \"fileName\": \"\",\n  \"fileSize\": 0,\n  \"useCase\": \"\",\n  \"useCaseMetadata\": \"\"\n}" in

Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/files",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => json_encode([
    'contentType' => '',
    'fileName' => '',
    'fileSize' => 0,
    'useCase' => '',
    'useCaseMetadata' => ''
  ]),
  CURLOPT_HTTPHEADER => [
    "content-type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('POST', '{{baseUrl}}/api/v1/w/:wId/files', [
  'body' => '{
  "contentType": "",
  "fileName": "",
  "fileSize": 0,
  "useCase": "",
  "useCaseMetadata": ""
}',
  'headers' => [
    'content-type' => 'application/json',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/files');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$request->setContentType('application/json');
$request->setBody(json_encode([
  'contentType' => '',
  'fileName' => '',
  'fileSize' => 0,
  'useCase' => '',
  'useCaseMetadata' => ''
]));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
append(json_encode([
  'contentType' => '',
  'fileName' => '',
  'fileSize' => 0,
  'useCase' => '',
  'useCaseMetadata' => ''
]));
$request->setRequestUrl('{{baseUrl}}/api/v1/w/:wId/files');
$request->setRequestMethod('POST');
$request->setBody($body);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/files' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "contentType": "",
  "fileName": "",
  "fileSize": 0,
  "useCase": "",
  "useCaseMetadata": ""
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/files' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "contentType": "",
  "fileName": "",
  "fileSize": 0,
  "useCase": "",
  "useCaseMetadata": ""
}'
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = "{\n  \"contentType\": \"\",\n  \"fileName\": \"\",\n  \"fileSize\": 0,\n  \"useCase\": \"\",\n  \"useCaseMetadata\": \"\"\n}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/baseUrl/api/v1/w/:wId/files", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/files"

payload = {
    "contentType": "",
    "fileName": "",
    "fileSize": 0,
    "useCase": "",
    "useCaseMetadata": ""
}
headers = {"content-type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/files"

payload <- "{\n  \"contentType\": \"\",\n  \"fileName\": \"\",\n  \"fileSize\": 0,\n  \"useCase\": \"\",\n  \"useCaseMetadata\": \"\"\n}"

encode <- "json"

response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/files")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\n  \"contentType\": \"\",\n  \"fileName\": \"\",\n  \"fileSize\": 0,\n  \"useCase\": \"\",\n  \"useCaseMetadata\": \"\"\n}"

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/json'}
)

response = conn.post('/baseUrl/api/v1/w/:wId/files') do |req|
  req.body = "{\n  \"contentType\": \"\",\n  \"fileName\": \"\",\n  \"fileSize\": 0,\n  \"useCase\": \"\",\n  \"useCaseMetadata\": \"\"\n}"
end

puts response.status
puts response.body
use serde_json::json;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/files";

    let payload = json!({
        "contentType": "",
        "fileName": "",
        "fileSize": 0,
        "useCase": "",
        "useCaseMetadata": ""
    });

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("content-type", "application/json".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.post(url)
        .headers(headers)
        .json(&payload)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request POST \
  --url {{baseUrl}}/api/v1/w/:wId/files \
  --header 'content-type: application/json' \
  --data '{
  "contentType": "",
  "fileName": "",
  "fileSize": 0,
  "useCase": "",
  "useCaseMetadata": ""
}'
echo '{
  "contentType": "",
  "fileName": "",
  "fileSize": 0,
  "useCase": "",
  "useCaseMetadata": ""
}' |  \
  http POST {{baseUrl}}/api/v1/w/:wId/files \
  content-type:application/json
wget --quiet \
  --method POST \
  --header 'content-type: application/json' \
  --body-data '{\n  "contentType": "",\n  "fileName": "",\n  "fileSize": 0,\n  "useCase": "",\n  "useCaseMetadata": ""\n}' \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/files
import Foundation

let headers = ["content-type": "application/json"]
let parameters = [
  "contentType": "",
  "fileName": "",
  "fileSize": 0,
  "useCase": "",
  "useCaseMetadata": ""
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/files")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
POST Create a message
{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages
QUERY PARAMS

wId
cId
BODY json

{
  "content": "",
  "mentions": [
    {
      "configurationId": ""
    }
  ],
  "context": {
    "username": "",
    "timezone": "",
    "fullName": "",
    "email": "",
    "profilePictureUrl": "",
    "origin": ""
  }
}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ],\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/post "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages" {:content-type :json
                                                                                                :form-params {:content ""
                                                                                                              :mentions [{:configurationId ""}]
                                                                                                              :context {:username ""
                                                                                                                        :timezone ""
                                                                                                                        :fullName ""
                                                                                                                        :email ""
                                                                                                                        :profilePictureUrl ""
                                                                                                                        :origin ""}}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages"
headers = HTTP::Headers{
  "content-type" => "application/json"
}
reqBody = "{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ],\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}"

response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Post,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages"),
    Content = new StringContent("{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ],\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}")
    {
        Headers =
        {
            ContentType = new MediaTypeHeaderValue("application/json")
        }
    }
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ],\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages"

	payload := strings.NewReader("{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ],\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("content-type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
POST /baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 223

{
  "content": "",
  "mentions": [
    {
      "configurationId": ""
    }
  ],
  "context": {
    "username": "",
    "timezone": "",
    "fullName": "",
    "email": "",
    "profilePictureUrl": "",
    "origin": ""
  }
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages")
  .setHeader("content-type", "application/json")
  .setBody("{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ],\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages"))
    .header("content-type", "application/json")
    .method("POST", HttpRequest.BodyPublishers.ofString("{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ],\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}"))
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ],\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}");
Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages")
  .post(body)
  .addHeader("content-type", "application/json")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages")
  .header("content-type", "application/json")
  .body("{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ],\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}")
  .asString();
const data = JSON.stringify({
  content: '',
  mentions: [
    {
      configurationId: ''
    }
  ],
  context: {
    username: '',
    timezone: '',
    fullName: '',
    email: '',
    profilePictureUrl: '',
    origin: ''
  }
});

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('POST', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages');
xhr.setRequestHeader('content-type', 'application/json');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages',
  headers: {'content-type': 'application/json'},
  data: {
    content: '',
    mentions: [{configurationId: ''}],
    context: {
      username: '',
      timezone: '',
      fullName: '',
      email: '',
      profilePictureUrl: '',
      origin: ''
    }
  }
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"content":"","mentions":[{"configurationId":""}],"context":{"username":"","timezone":"","fullName":"","email":"","profilePictureUrl":"","origin":""}}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages',
  method: 'POST',
  headers: {
    'content-type': 'application/json'
  },
  processData: false,
  data: '{\n  "content": "",\n  "mentions": [\n    {\n      "configurationId": ""\n    }\n  ],\n  "context": {\n    "username": "",\n    "timezone": "",\n    "fullName": "",\n    "email": "",\n    "profilePictureUrl": "",\n    "origin": ""\n  }\n}'
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ],\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}")
val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages")
  .post(body)
  .addHeader("content-type", "application/json")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'POST',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages',
  headers: {
    'content-type': 'application/json'
  }
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.write(JSON.stringify({
  content: '',
  mentions: [{configurationId: ''}],
  context: {
    username: '',
    timezone: '',
    fullName: '',
    email: '',
    profilePictureUrl: '',
    origin: ''
  }
}));
req.end();
const request = require('request');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages',
  headers: {'content-type': 'application/json'},
  body: {
    content: '',
    mentions: [{configurationId: ''}],
    context: {
      username: '',
      timezone: '',
      fullName: '',
      email: '',
      profilePictureUrl: '',
      origin: ''
    }
  },
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('POST', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages');

req.headers({
  'content-type': 'application/json'
});

req.type('json');
req.send({
  content: '',
  mentions: [
    {
      configurationId: ''
    }
  ],
  context: {
    username: '',
    timezone: '',
    fullName: '',
    email: '',
    profilePictureUrl: '',
    origin: ''
  }
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages',
  headers: {'content-type': 'application/json'},
  data: {
    content: '',
    mentions: [{configurationId: ''}],
    context: {
      username: '',
      timezone: '',
      fullName: '',
      email: '',
      profilePictureUrl: '',
      origin: ''
    }
  }
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"content":"","mentions":[{"configurationId":""}],"context":{"username":"","timezone":"","fullName":"","email":"","profilePictureUrl":"","origin":""}}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"content": @"",
                              @"mentions": @[ @{ @"configurationId": @"" } ],
                              @"context": @{ @"username": @"", @"timezone": @"", @"fullName": @"", @"email": @"", @"profilePictureUrl": @"", @"origin": @"" } };

NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ],\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}" in

Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => json_encode([
    'content' => '',
    'mentions' => [
        [
                'configurationId' => ''
        ]
    ],
    'context' => [
        'username' => '',
        'timezone' => '',
        'fullName' => '',
        'email' => '',
        'profilePictureUrl' => '',
        'origin' => ''
    ]
  ]),
  CURLOPT_HTTPHEADER => [
    "content-type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('POST', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages', [
  'body' => '{
  "content": "",
  "mentions": [
    {
      "configurationId": ""
    }
  ],
  "context": {
    "username": "",
    "timezone": "",
    "fullName": "",
    "email": "",
    "profilePictureUrl": "",
    "origin": ""
  }
}',
  'headers' => [
    'content-type' => 'application/json',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$request->setContentType('application/json');
$request->setBody(json_encode([
  'content' => '',
  'mentions' => [
    [
        'configurationId' => ''
    ]
  ],
  'context' => [
    'username' => '',
    'timezone' => '',
    'fullName' => '',
    'email' => '',
    'profilePictureUrl' => '',
    'origin' => ''
  ]
]));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
append(json_encode([
  'content' => '',
  'mentions' => [
    [
        'configurationId' => ''
    ]
  ],
  'context' => [
    'username' => '',
    'timezone' => '',
    'fullName' => '',
    'email' => '',
    'profilePictureUrl' => '',
    'origin' => ''
  ]
]));
$request->setRequestUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages');
$request->setRequestMethod('POST');
$request->setBody($body);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "content": "",
  "mentions": [
    {
      "configurationId": ""
    }
  ],
  "context": {
    "username": "",
    "timezone": "",
    "fullName": "",
    "email": "",
    "profilePictureUrl": "",
    "origin": ""
  }
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "content": "",
  "mentions": [
    {
      "configurationId": ""
    }
  ],
  "context": {
    "username": "",
    "timezone": "",
    "fullName": "",
    "email": "",
    "profilePictureUrl": "",
    "origin": ""
  }
}'
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = "{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ],\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages"

payload = {
    "content": "",
    "mentions": [{ "configurationId": "" }],
    "context": {
        "username": "",
        "timezone": "",
        "fullName": "",
        "email": "",
        "profilePictureUrl": "",
        "origin": ""
    }
}
headers = {"content-type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages"

payload <- "{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ],\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}"

encode <- "json"

response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ],\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}"

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/json'}
)

response = conn.post('/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages') do |req|
  req.body = "{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ],\n  \"context\": {\n    \"username\": \"\",\n    \"timezone\": \"\",\n    \"fullName\": \"\",\n    \"email\": \"\",\n    \"profilePictureUrl\": \"\",\n    \"origin\": \"\"\n  }\n}"
end

puts response.status
puts response.body
use serde_json::json;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages";

    let payload = json!({
        "content": "",
        "mentions": (json!({"configurationId": ""})),
        "context": json!({
            "username": "",
            "timezone": "",
            "fullName": "",
            "email": "",
            "profilePictureUrl": "",
            "origin": ""
        })
    });

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("content-type", "application/json".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.post(url)
        .headers(headers)
        .json(&payload)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request POST \
  --url {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages \
  --header 'content-type: application/json' \
  --data '{
  "content": "",
  "mentions": [
    {
      "configurationId": ""
    }
  ],
  "context": {
    "username": "",
    "timezone": "",
    "fullName": "",
    "email": "",
    "profilePictureUrl": "",
    "origin": ""
  }
}'
echo '{
  "content": "",
  "mentions": [
    {
      "configurationId": ""
    }
  ],
  "context": {
    "username": "",
    "timezone": "",
    "fullName": "",
    "email": "",
    "profilePictureUrl": "",
    "origin": ""
  }
}' |  \
  http POST {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages \
  content-type:application/json
wget --quiet \
  --method POST \
  --header 'content-type: application/json' \
  --body-data '{\n  "content": "",\n  "mentions": [\n    {\n      "configurationId": ""\n    }\n  ],\n  "context": {\n    "username": "",\n    "timezone": "",\n    "fullName": "",\n    "email": "",\n    "profilePictureUrl": "",\n    "origin": ""\n  }\n}' \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages
import Foundation

let headers = ["content-type": "application/json"]
let parameters = [
  "content": "",
  "mentions": [["configurationId": ""]],
  "context": [
    "username": "",
    "timezone": "",
    "fullName": "",
    "email": "",
    "profilePictureUrl": "",
    "origin": ""
  ]
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "content": "This is my message",
  "context": {
    "username": "johndoe123",
    "timezone": "America/New_York",
    "fullName": "John Doe",
    "email": "john.doe@example.com",
    "profilePictureUrl": "https://example.com/profiles/johndoe123.jpg"
  }
}
POST Create a new conversation
{{baseUrl}}/api/v1/w/:wId/assistant/conversations
QUERY PARAMS

wId
BODY json

{
  "message": {
    "content": "",
    "mentions": [
      {
        "configurationId": ""
      }
    ],
    "context": {
      "username": "",
      "timezone": "",
      "fullName": "",
      "email": "",
      "profilePictureUrl": "",
      "origin": ""
    }
  },
  "contentFragments": [
    {
      "title": "",
      "content": "",
      "contentType": "",
      "url": "",
      "fileId": "",
      "nodeId": "",
      "nodeDataSourceViewId": "",
      "context": {}
    }
  ],
  "title": "",
  "skipToolsValidation": false,
  "blocking": false
}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/assistant/conversations");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n  \"message\": {\n    \"content\": \"\",\n    \"mentions\": [\n      {\n        \"configurationId\": \"\"\n      }\n    ],\n    \"context\": {\n      \"username\": \"\",\n      \"timezone\": \"\",\n      \"fullName\": \"\",\n      \"email\": \"\",\n      \"profilePictureUrl\": \"\",\n      \"origin\": \"\"\n    }\n  },\n  \"contentFragments\": [\n    {\n      \"title\": \"\",\n      \"content\": \"\",\n      \"contentType\": \"\",\n      \"url\": \"\",\n      \"fileId\": \"\",\n      \"nodeId\": \"\",\n      \"nodeDataSourceViewId\": \"\",\n      \"context\": {}\n    }\n  ],\n  \"title\": \"\",\n  \"skipToolsValidation\": false,\n  \"blocking\": false\n}");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/post "{{baseUrl}}/api/v1/w/:wId/assistant/conversations" {:content-type :json
                                                                                  :form-params {:message {:content ""
                                                                                                          :mentions [{:configurationId ""}]
                                                                                                          :context {:username ""
                                                                                                                    :timezone ""
                                                                                                                    :fullName ""
                                                                                                                    :email ""
                                                                                                                    :profilePictureUrl ""
                                                                                                                    :origin ""}}
                                                                                                :contentFragments [{:title ""
                                                                                                                    :content ""
                                                                                                                    :contentType ""
                                                                                                                    :url ""
                                                                                                                    :fileId ""
                                                                                                                    :nodeId ""
                                                                                                                    :nodeDataSourceViewId ""
                                                                                                                    :context {}}]
                                                                                                :title ""
                                                                                                :skipToolsValidation false
                                                                                                :blocking false}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations"
headers = HTTP::Headers{
  "content-type" => "application/json"
}
reqBody = "{\n  \"message\": {\n    \"content\": \"\",\n    \"mentions\": [\n      {\n        \"configurationId\": \"\"\n      }\n    ],\n    \"context\": {\n      \"username\": \"\",\n      \"timezone\": \"\",\n      \"fullName\": \"\",\n      \"email\": \"\",\n      \"profilePictureUrl\": \"\",\n      \"origin\": \"\"\n    }\n  },\n  \"contentFragments\": [\n    {\n      \"title\": \"\",\n      \"content\": \"\",\n      \"contentType\": \"\",\n      \"url\": \"\",\n      \"fileId\": \"\",\n      \"nodeId\": \"\",\n      \"nodeDataSourceViewId\": \"\",\n      \"context\": {}\n    }\n  ],\n  \"title\": \"\",\n  \"skipToolsValidation\": false,\n  \"blocking\": false\n}"

response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Post,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/assistant/conversations"),
    Content = new StringContent("{\n  \"message\": {\n    \"content\": \"\",\n    \"mentions\": [\n      {\n        \"configurationId\": \"\"\n      }\n    ],\n    \"context\": {\n      \"username\": \"\",\n      \"timezone\": \"\",\n      \"fullName\": \"\",\n      \"email\": \"\",\n      \"profilePictureUrl\": \"\",\n      \"origin\": \"\"\n    }\n  },\n  \"contentFragments\": [\n    {\n      \"title\": \"\",\n      \"content\": \"\",\n      \"contentType\": \"\",\n      \"url\": \"\",\n      \"fileId\": \"\",\n      \"nodeId\": \"\",\n      \"nodeDataSourceViewId\": \"\",\n      \"context\": {}\n    }\n  ],\n  \"title\": \"\",\n  \"skipToolsValidation\": false,\n  \"blocking\": false\n}")
    {
        Headers =
        {
            ContentType = new MediaTypeHeaderValue("application/json")
        }
    }
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/assistant/conversations");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n  \"message\": {\n    \"content\": \"\",\n    \"mentions\": [\n      {\n        \"configurationId\": \"\"\n      }\n    ],\n    \"context\": {\n      \"username\": \"\",\n      \"timezone\": \"\",\n      \"fullName\": \"\",\n      \"email\": \"\",\n      \"profilePictureUrl\": \"\",\n      \"origin\": \"\"\n    }\n  },\n  \"contentFragments\": [\n    {\n      \"title\": \"\",\n      \"content\": \"\",\n      \"contentType\": \"\",\n      \"url\": \"\",\n      \"fileId\": \"\",\n      \"nodeId\": \"\",\n      \"nodeDataSourceViewId\": \"\",\n      \"context\": {}\n    }\n  ],\n  \"title\": \"\",\n  \"skipToolsValidation\": false,\n  \"blocking\": false\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/assistant/conversations"

	payload := strings.NewReader("{\n  \"message\": {\n    \"content\": \"\",\n    \"mentions\": [\n      {\n        \"configurationId\": \"\"\n      }\n    ],\n    \"context\": {\n      \"username\": \"\",\n      \"timezone\": \"\",\n      \"fullName\": \"\",\n      \"email\": \"\",\n      \"profilePictureUrl\": \"\",\n      \"origin\": \"\"\n    }\n  },\n  \"contentFragments\": [\n    {\n      \"title\": \"\",\n      \"content\": \"\",\n      \"contentType\": \"\",\n      \"url\": \"\",\n      \"fileId\": \"\",\n      \"nodeId\": \"\",\n      \"nodeDataSourceViewId\": \"\",\n      \"context\": {}\n    }\n  ],\n  \"title\": \"\",\n  \"skipToolsValidation\": false,\n  \"blocking\": false\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("content-type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
POST /baseUrl/api/v1/w/:wId/assistant/conversations HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 555

{
  "message": {
    "content": "",
    "mentions": [
      {
        "configurationId": ""
      }
    ],
    "context": {
      "username": "",
      "timezone": "",
      "fullName": "",
      "email": "",
      "profilePictureUrl": "",
      "origin": ""
    }
  },
  "contentFragments": [
    {
      "title": "",
      "content": "",
      "contentType": "",
      "url": "",
      "fileId": "",
      "nodeId": "",
      "nodeDataSourceViewId": "",
      "context": {}
    }
  ],
  "title": "",
  "skipToolsValidation": false,
  "blocking": false
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/api/v1/w/:wId/assistant/conversations")
  .setHeader("content-type", "application/json")
  .setBody("{\n  \"message\": {\n    \"content\": \"\",\n    \"mentions\": [\n      {\n        \"configurationId\": \"\"\n      }\n    ],\n    \"context\": {\n      \"username\": \"\",\n      \"timezone\": \"\",\n      \"fullName\": \"\",\n      \"email\": \"\",\n      \"profilePictureUrl\": \"\",\n      \"origin\": \"\"\n    }\n  },\n  \"contentFragments\": [\n    {\n      \"title\": \"\",\n      \"content\": \"\",\n      \"contentType\": \"\",\n      \"url\": \"\",\n      \"fileId\": \"\",\n      \"nodeId\": \"\",\n      \"nodeDataSourceViewId\": \"\",\n      \"context\": {}\n    }\n  ],\n  \"title\": \"\",\n  \"skipToolsValidation\": false,\n  \"blocking\": false\n}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/assistant/conversations"))
    .header("content-type", "application/json")
    .method("POST", HttpRequest.BodyPublishers.ofString("{\n  \"message\": {\n    \"content\": \"\",\n    \"mentions\": [\n      {\n        \"configurationId\": \"\"\n      }\n    ],\n    \"context\": {\n      \"username\": \"\",\n      \"timezone\": \"\",\n      \"fullName\": \"\",\n      \"email\": \"\",\n      \"profilePictureUrl\": \"\",\n      \"origin\": \"\"\n    }\n  },\n  \"contentFragments\": [\n    {\n      \"title\": \"\",\n      \"content\": \"\",\n      \"contentType\": \"\",\n      \"url\": \"\",\n      \"fileId\": \"\",\n      \"nodeId\": \"\",\n      \"nodeDataSourceViewId\": \"\",\n      \"context\": {}\n    }\n  ],\n  \"title\": \"\",\n  \"skipToolsValidation\": false,\n  \"blocking\": false\n}"))
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n  \"message\": {\n    \"content\": \"\",\n    \"mentions\": [\n      {\n        \"configurationId\": \"\"\n      }\n    ],\n    \"context\": {\n      \"username\": \"\",\n      \"timezone\": \"\",\n      \"fullName\": \"\",\n      \"email\": \"\",\n      \"profilePictureUrl\": \"\",\n      \"origin\": \"\"\n    }\n  },\n  \"contentFragments\": [\n    {\n      \"title\": \"\",\n      \"content\": \"\",\n      \"contentType\": \"\",\n      \"url\": \"\",\n      \"fileId\": \"\",\n      \"nodeId\": \"\",\n      \"nodeDataSourceViewId\": \"\",\n      \"context\": {}\n    }\n  ],\n  \"title\": \"\",\n  \"skipToolsValidation\": false,\n  \"blocking\": false\n}");
Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations")
  .post(body)
  .addHeader("content-type", "application/json")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/api/v1/w/:wId/assistant/conversations")
  .header("content-type", "application/json")
  .body("{\n  \"message\": {\n    \"content\": \"\",\n    \"mentions\": [\n      {\n        \"configurationId\": \"\"\n      }\n    ],\n    \"context\": {\n      \"username\": \"\",\n      \"timezone\": \"\",\n      \"fullName\": \"\",\n      \"email\": \"\",\n      \"profilePictureUrl\": \"\",\n      \"origin\": \"\"\n    }\n  },\n  \"contentFragments\": [\n    {\n      \"title\": \"\",\n      \"content\": \"\",\n      \"contentType\": \"\",\n      \"url\": \"\",\n      \"fileId\": \"\",\n      \"nodeId\": \"\",\n      \"nodeDataSourceViewId\": \"\",\n      \"context\": {}\n    }\n  ],\n  \"title\": \"\",\n  \"skipToolsValidation\": false,\n  \"blocking\": false\n}")
  .asString();
const data = JSON.stringify({
  message: {
    content: '',
    mentions: [
      {
        configurationId: ''
      }
    ],
    context: {
      username: '',
      timezone: '',
      fullName: '',
      email: '',
      profilePictureUrl: '',
      origin: ''
    }
  },
  contentFragments: [
    {
      title: '',
      content: '',
      contentType: '',
      url: '',
      fileId: '',
      nodeId: '',
      nodeDataSourceViewId: '',
      context: {}
    }
  ],
  title: '',
  skipToolsValidation: false,
  blocking: false
});

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('POST', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations');
xhr.setRequestHeader('content-type', 'application/json');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations',
  headers: {'content-type': 'application/json'},
  data: {
    message: {
      content: '',
      mentions: [{configurationId: ''}],
      context: {
        username: '',
        timezone: '',
        fullName: '',
        email: '',
        profilePictureUrl: '',
        origin: ''
      }
    },
    contentFragments: [
      {
        title: '',
        content: '',
        contentType: '',
        url: '',
        fileId: '',
        nodeId: '',
        nodeDataSourceViewId: '',
        context: {}
      }
    ],
    title: '',
    skipToolsValidation: false,
    blocking: false
  }
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"message":{"content":"","mentions":[{"configurationId":""}],"context":{"username":"","timezone":"","fullName":"","email":"","profilePictureUrl":"","origin":""}},"contentFragments":[{"title":"","content":"","contentType":"","url":"","fileId":"","nodeId":"","nodeDataSourceViewId":"","context":{}}],"title":"","skipToolsValidation":false,"blocking":false}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations',
  method: 'POST',
  headers: {
    'content-type': 'application/json'
  },
  processData: false,
  data: '{\n  "message": {\n    "content": "",\n    "mentions": [\n      {\n        "configurationId": ""\n      }\n    ],\n    "context": {\n      "username": "",\n      "timezone": "",\n      "fullName": "",\n      "email": "",\n      "profilePictureUrl": "",\n      "origin": ""\n    }\n  },\n  "contentFragments": [\n    {\n      "title": "",\n      "content": "",\n      "contentType": "",\n      "url": "",\n      "fileId": "",\n      "nodeId": "",\n      "nodeDataSourceViewId": "",\n      "context": {}\n    }\n  ],\n  "title": "",\n  "skipToolsValidation": false,\n  "blocking": false\n}'
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n  \"message\": {\n    \"content\": \"\",\n    \"mentions\": [\n      {\n        \"configurationId\": \"\"\n      }\n    ],\n    \"context\": {\n      \"username\": \"\",\n      \"timezone\": \"\",\n      \"fullName\": \"\",\n      \"email\": \"\",\n      \"profilePictureUrl\": \"\",\n      \"origin\": \"\"\n    }\n  },\n  \"contentFragments\": [\n    {\n      \"title\": \"\",\n      \"content\": \"\",\n      \"contentType\": \"\",\n      \"url\": \"\",\n      \"fileId\": \"\",\n      \"nodeId\": \"\",\n      \"nodeDataSourceViewId\": \"\",\n      \"context\": {}\n    }\n  ],\n  \"title\": \"\",\n  \"skipToolsValidation\": false,\n  \"blocking\": false\n}")
val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations")
  .post(body)
  .addHeader("content-type", "application/json")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'POST',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/assistant/conversations',
  headers: {
    'content-type': 'application/json'
  }
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.write(JSON.stringify({
  message: {
    content: '',
    mentions: [{configurationId: ''}],
    context: {
      username: '',
      timezone: '',
      fullName: '',
      email: '',
      profilePictureUrl: '',
      origin: ''
    }
  },
  contentFragments: [
    {
      title: '',
      content: '',
      contentType: '',
      url: '',
      fileId: '',
      nodeId: '',
      nodeDataSourceViewId: '',
      context: {}
    }
  ],
  title: '',
  skipToolsValidation: false,
  blocking: false
}));
req.end();
const request = require('request');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations',
  headers: {'content-type': 'application/json'},
  body: {
    message: {
      content: '',
      mentions: [{configurationId: ''}],
      context: {
        username: '',
        timezone: '',
        fullName: '',
        email: '',
        profilePictureUrl: '',
        origin: ''
      }
    },
    contentFragments: [
      {
        title: '',
        content: '',
        contentType: '',
        url: '',
        fileId: '',
        nodeId: '',
        nodeDataSourceViewId: '',
        context: {}
      }
    ],
    title: '',
    skipToolsValidation: false,
    blocking: false
  },
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('POST', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations');

req.headers({
  'content-type': 'application/json'
});

req.type('json');
req.send({
  message: {
    content: '',
    mentions: [
      {
        configurationId: ''
      }
    ],
    context: {
      username: '',
      timezone: '',
      fullName: '',
      email: '',
      profilePictureUrl: '',
      origin: ''
    }
  },
  contentFragments: [
    {
      title: '',
      content: '',
      contentType: '',
      url: '',
      fileId: '',
      nodeId: '',
      nodeDataSourceViewId: '',
      context: {}
    }
  ],
  title: '',
  skipToolsValidation: false,
  blocking: false
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations',
  headers: {'content-type': 'application/json'},
  data: {
    message: {
      content: '',
      mentions: [{configurationId: ''}],
      context: {
        username: '',
        timezone: '',
        fullName: '',
        email: '',
        profilePictureUrl: '',
        origin: ''
      }
    },
    contentFragments: [
      {
        title: '',
        content: '',
        contentType: '',
        url: '',
        fileId: '',
        nodeId: '',
        nodeDataSourceViewId: '',
        context: {}
      }
    ],
    title: '',
    skipToolsValidation: false,
    blocking: false
  }
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"message":{"content":"","mentions":[{"configurationId":""}],"context":{"username":"","timezone":"","fullName":"","email":"","profilePictureUrl":"","origin":""}},"contentFragments":[{"title":"","content":"","contentType":"","url":"","fileId":"","nodeId":"","nodeDataSourceViewId":"","context":{}}],"title":"","skipToolsValidation":false,"blocking":false}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"message": @{ @"content": @"", @"mentions": @[ @{ @"configurationId": @"" } ], @"context": @{ @"username": @"", @"timezone": @"", @"fullName": @"", @"email": @"", @"profilePictureUrl": @"", @"origin": @"" } },
                              @"contentFragments": @[ @{ @"title": @"", @"content": @"", @"contentType": @"", @"url": @"", @"fileId": @"", @"nodeId": @"", @"nodeDataSourceViewId": @"", @"context": @{  } } ],
                              @"title": @"",
                              @"skipToolsValidation": @NO,
                              @"blocking": @NO };

NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/assistant/conversations"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/assistant/conversations" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n  \"message\": {\n    \"content\": \"\",\n    \"mentions\": [\n      {\n        \"configurationId\": \"\"\n      }\n    ],\n    \"context\": {\n      \"username\": \"\",\n      \"timezone\": \"\",\n      \"fullName\": \"\",\n      \"email\": \"\",\n      \"profilePictureUrl\": \"\",\n      \"origin\": \"\"\n    }\n  },\n  \"contentFragments\": [\n    {\n      \"title\": \"\",\n      \"content\": \"\",\n      \"contentType\": \"\",\n      \"url\": \"\",\n      \"fileId\": \"\",\n      \"nodeId\": \"\",\n      \"nodeDataSourceViewId\": \"\",\n      \"context\": {}\n    }\n  ],\n  \"title\": \"\",\n  \"skipToolsValidation\": false,\n  \"blocking\": false\n}" in

Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/assistant/conversations",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => json_encode([
    'message' => [
        'content' => '',
        'mentions' => [
                [
                                'configurationId' => ''
                ]
        ],
        'context' => [
                'username' => '',
                'timezone' => '',
                'fullName' => '',
                'email' => '',
                'profilePictureUrl' => '',
                'origin' => ''
        ]
    ],
    'contentFragments' => [
        [
                'title' => '',
                'content' => '',
                'contentType' => '',
                'url' => '',
                'fileId' => '',
                'nodeId' => '',
                'nodeDataSourceViewId' => '',
                'context' => [
                                
                ]
        ]
    ],
    'title' => '',
    'skipToolsValidation' => null,
    'blocking' => null
  ]),
  CURLOPT_HTTPHEADER => [
    "content-type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('POST', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations', [
  'body' => '{
  "message": {
    "content": "",
    "mentions": [
      {
        "configurationId": ""
      }
    ],
    "context": {
      "username": "",
      "timezone": "",
      "fullName": "",
      "email": "",
      "profilePictureUrl": "",
      "origin": ""
    }
  },
  "contentFragments": [
    {
      "title": "",
      "content": "",
      "contentType": "",
      "url": "",
      "fileId": "",
      "nodeId": "",
      "nodeDataSourceViewId": "",
      "context": {}
    }
  ],
  "title": "",
  "skipToolsValidation": false,
  "blocking": false
}',
  'headers' => [
    'content-type' => 'application/json',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$request->setContentType('application/json');
$request->setBody(json_encode([
  'message' => [
    'content' => '',
    'mentions' => [
        [
                'configurationId' => ''
        ]
    ],
    'context' => [
        'username' => '',
        'timezone' => '',
        'fullName' => '',
        'email' => '',
        'profilePictureUrl' => '',
        'origin' => ''
    ]
  ],
  'contentFragments' => [
    [
        'title' => '',
        'content' => '',
        'contentType' => '',
        'url' => '',
        'fileId' => '',
        'nodeId' => '',
        'nodeDataSourceViewId' => '',
        'context' => [
                
        ]
    ]
  ],
  'title' => '',
  'skipToolsValidation' => null,
  'blocking' => null
]));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
append(json_encode([
  'message' => [
    'content' => '',
    'mentions' => [
        [
                'configurationId' => ''
        ]
    ],
    'context' => [
        'username' => '',
        'timezone' => '',
        'fullName' => '',
        'email' => '',
        'profilePictureUrl' => '',
        'origin' => ''
    ]
  ],
  'contentFragments' => [
    [
        'title' => '',
        'content' => '',
        'contentType' => '',
        'url' => '',
        'fileId' => '',
        'nodeId' => '',
        'nodeDataSourceViewId' => '',
        'context' => [
                
        ]
    ]
  ],
  'title' => '',
  'skipToolsValidation' => null,
  'blocking' => null
]));
$request->setRequestUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations');
$request->setRequestMethod('POST');
$request->setBody($body);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "message": {
    "content": "",
    "mentions": [
      {
        "configurationId": ""
      }
    ],
    "context": {
      "username": "",
      "timezone": "",
      "fullName": "",
      "email": "",
      "profilePictureUrl": "",
      "origin": ""
    }
  },
  "contentFragments": [
    {
      "title": "",
      "content": "",
      "contentType": "",
      "url": "",
      "fileId": "",
      "nodeId": "",
      "nodeDataSourceViewId": "",
      "context": {}
    }
  ],
  "title": "",
  "skipToolsValidation": false,
  "blocking": false
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "message": {
    "content": "",
    "mentions": [
      {
        "configurationId": ""
      }
    ],
    "context": {
      "username": "",
      "timezone": "",
      "fullName": "",
      "email": "",
      "profilePictureUrl": "",
      "origin": ""
    }
  },
  "contentFragments": [
    {
      "title": "",
      "content": "",
      "contentType": "",
      "url": "",
      "fileId": "",
      "nodeId": "",
      "nodeDataSourceViewId": "",
      "context": {}
    }
  ],
  "title": "",
  "skipToolsValidation": false,
  "blocking": false
}'
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = "{\n  \"message\": {\n    \"content\": \"\",\n    \"mentions\": [\n      {\n        \"configurationId\": \"\"\n      }\n    ],\n    \"context\": {\n      \"username\": \"\",\n      \"timezone\": \"\",\n      \"fullName\": \"\",\n      \"email\": \"\",\n      \"profilePictureUrl\": \"\",\n      \"origin\": \"\"\n    }\n  },\n  \"contentFragments\": [\n    {\n      \"title\": \"\",\n      \"content\": \"\",\n      \"contentType\": \"\",\n      \"url\": \"\",\n      \"fileId\": \"\",\n      \"nodeId\": \"\",\n      \"nodeDataSourceViewId\": \"\",\n      \"context\": {}\n    }\n  ],\n  \"title\": \"\",\n  \"skipToolsValidation\": false,\n  \"blocking\": false\n}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/baseUrl/api/v1/w/:wId/assistant/conversations", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations"

payload = {
    "message": {
        "content": "",
        "mentions": [{ "configurationId": "" }],
        "context": {
            "username": "",
            "timezone": "",
            "fullName": "",
            "email": "",
            "profilePictureUrl": "",
            "origin": ""
        }
    },
    "contentFragments": [
        {
            "title": "",
            "content": "",
            "contentType": "",
            "url": "",
            "fileId": "",
            "nodeId": "",
            "nodeDataSourceViewId": "",
            "context": {}
        }
    ],
    "title": "",
    "skipToolsValidation": False,
    "blocking": False
}
headers = {"content-type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/assistant/conversations"

payload <- "{\n  \"message\": {\n    \"content\": \"\",\n    \"mentions\": [\n      {\n        \"configurationId\": \"\"\n      }\n    ],\n    \"context\": {\n      \"username\": \"\",\n      \"timezone\": \"\",\n      \"fullName\": \"\",\n      \"email\": \"\",\n      \"profilePictureUrl\": \"\",\n      \"origin\": \"\"\n    }\n  },\n  \"contentFragments\": [\n    {\n      \"title\": \"\",\n      \"content\": \"\",\n      \"contentType\": \"\",\n      \"url\": \"\",\n      \"fileId\": \"\",\n      \"nodeId\": \"\",\n      \"nodeDataSourceViewId\": \"\",\n      \"context\": {}\n    }\n  ],\n  \"title\": \"\",\n  \"skipToolsValidation\": false,\n  \"blocking\": false\n}"

encode <- "json"

response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/assistant/conversations")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\n  \"message\": {\n    \"content\": \"\",\n    \"mentions\": [\n      {\n        \"configurationId\": \"\"\n      }\n    ],\n    \"context\": {\n      \"username\": \"\",\n      \"timezone\": \"\",\n      \"fullName\": \"\",\n      \"email\": \"\",\n      \"profilePictureUrl\": \"\",\n      \"origin\": \"\"\n    }\n  },\n  \"contentFragments\": [\n    {\n      \"title\": \"\",\n      \"content\": \"\",\n      \"contentType\": \"\",\n      \"url\": \"\",\n      \"fileId\": \"\",\n      \"nodeId\": \"\",\n      \"nodeDataSourceViewId\": \"\",\n      \"context\": {}\n    }\n  ],\n  \"title\": \"\",\n  \"skipToolsValidation\": false,\n  \"blocking\": false\n}"

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/json'}
)

response = conn.post('/baseUrl/api/v1/w/:wId/assistant/conversations') do |req|
  req.body = "{\n  \"message\": {\n    \"content\": \"\",\n    \"mentions\": [\n      {\n        \"configurationId\": \"\"\n      }\n    ],\n    \"context\": {\n      \"username\": \"\",\n      \"timezone\": \"\",\n      \"fullName\": \"\",\n      \"email\": \"\",\n      \"profilePictureUrl\": \"\",\n      \"origin\": \"\"\n    }\n  },\n  \"contentFragments\": [\n    {\n      \"title\": \"\",\n      \"content\": \"\",\n      \"contentType\": \"\",\n      \"url\": \"\",\n      \"fileId\": \"\",\n      \"nodeId\": \"\",\n      \"nodeDataSourceViewId\": \"\",\n      \"context\": {}\n    }\n  ],\n  \"title\": \"\",\n  \"skipToolsValidation\": false,\n  \"blocking\": false\n}"
end

puts response.status
puts response.body
use serde_json::json;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations";

    let payload = json!({
        "message": json!({
            "content": "",
            "mentions": (json!({"configurationId": ""})),
            "context": json!({
                "username": "",
                "timezone": "",
                "fullName": "",
                "email": "",
                "profilePictureUrl": "",
                "origin": ""
            })
        }),
        "contentFragments": (
            json!({
                "title": "",
                "content": "",
                "contentType": "",
                "url": "",
                "fileId": "",
                "nodeId": "",
                "nodeDataSourceViewId": "",
                "context": json!({})
            })
        ),
        "title": "",
        "skipToolsValidation": false,
        "blocking": false
    });

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("content-type", "application/json".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.post(url)
        .headers(headers)
        .json(&payload)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request POST \
  --url {{baseUrl}}/api/v1/w/:wId/assistant/conversations \
  --header 'content-type: application/json' \
  --data '{
  "message": {
    "content": "",
    "mentions": [
      {
        "configurationId": ""
      }
    ],
    "context": {
      "username": "",
      "timezone": "",
      "fullName": "",
      "email": "",
      "profilePictureUrl": "",
      "origin": ""
    }
  },
  "contentFragments": [
    {
      "title": "",
      "content": "",
      "contentType": "",
      "url": "",
      "fileId": "",
      "nodeId": "",
      "nodeDataSourceViewId": "",
      "context": {}
    }
  ],
  "title": "",
  "skipToolsValidation": false,
  "blocking": false
}'
echo '{
  "message": {
    "content": "",
    "mentions": [
      {
        "configurationId": ""
      }
    ],
    "context": {
      "username": "",
      "timezone": "",
      "fullName": "",
      "email": "",
      "profilePictureUrl": "",
      "origin": ""
    }
  },
  "contentFragments": [
    {
      "title": "",
      "content": "",
      "contentType": "",
      "url": "",
      "fileId": "",
      "nodeId": "",
      "nodeDataSourceViewId": "",
      "context": {}
    }
  ],
  "title": "",
  "skipToolsValidation": false,
  "blocking": false
}' |  \
  http POST {{baseUrl}}/api/v1/w/:wId/assistant/conversations \
  content-type:application/json
wget --quiet \
  --method POST \
  --header 'content-type: application/json' \
  --body-data '{\n  "message": {\n    "content": "",\n    "mentions": [\n      {\n        "configurationId": ""\n      }\n    ],\n    "context": {\n      "username": "",\n      "timezone": "",\n      "fullName": "",\n      "email": "",\n      "profilePictureUrl": "",\n      "origin": ""\n    }\n  },\n  "contentFragments": [\n    {\n      "title": "",\n      "content": "",\n      "contentType": "",\n      "url": "",\n      "fileId": "",\n      "nodeId": "",\n      "nodeDataSourceViewId": "",\n      "context": {}\n    }\n  ],\n  "title": "",\n  "skipToolsValidation": false,\n  "blocking": false\n}' \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/assistant/conversations
import Foundation

let headers = ["content-type": "application/json"]
let parameters = [
  "message": [
    "content": "",
    "mentions": [["configurationId": ""]],
    "context": [
      "username": "",
      "timezone": "",
      "fullName": "",
      "email": "",
      "profilePictureUrl": "",
      "origin": ""
    ]
  ],
  "contentFragments": [
    [
      "title": "",
      "content": "",
      "contentType": "",
      "url": "",
      "fileId": "",
      "nodeId": "",
      "nodeDataSourceViewId": "",
      "context": []
    ]
  ],
  "title": "",
  "skipToolsValidation": false,
  "blocking": false
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/assistant/conversations")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "conversation": {
    "id": 67890,
    "created": 1625097600,
    "sId": "3d8f6a2c1b",
    "title": "Customer Inquiry #1234",
    "visibility": "private"
  }
}
POST Edit an existing message in a conversation
{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit
QUERY PARAMS

wId
cId
mId
BODY json

{
  "content": "",
  "mentions": [
    {
      "configurationId": ""
    }
  ]
}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ]\n}");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/post "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit" {:content-type :json
                                                                                                          :form-params {:content ""
                                                                                                                        :mentions [{:configurationId ""}]}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit"
headers = HTTP::Headers{
  "content-type" => "application/json"
}
reqBody = "{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ]\n}"

response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Post,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit"),
    Content = new StringContent("{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ]\n}")
    {
        Headers =
        {
            ContentType = new MediaTypeHeaderValue("application/json")
        }
    }
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ]\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit"

	payload := strings.NewReader("{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ]\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("content-type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
POST /baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 80

{
  "content": "",
  "mentions": [
    {
      "configurationId": ""
    }
  ]
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit")
  .setHeader("content-type", "application/json")
  .setBody("{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ]\n}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit"))
    .header("content-type", "application/json")
    .method("POST", HttpRequest.BodyPublishers.ofString("{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ]\n}"))
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ]\n}");
Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit")
  .post(body)
  .addHeader("content-type", "application/json")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit")
  .header("content-type", "application/json")
  .body("{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ]\n}")
  .asString();
const data = JSON.stringify({
  content: '',
  mentions: [
    {
      configurationId: ''
    }
  ]
});

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('POST', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit');
xhr.setRequestHeader('content-type', 'application/json');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit',
  headers: {'content-type': 'application/json'},
  data: {content: '', mentions: [{configurationId: ''}]}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"content":"","mentions":[{"configurationId":""}]}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit',
  method: 'POST',
  headers: {
    'content-type': 'application/json'
  },
  processData: false,
  data: '{\n  "content": "",\n  "mentions": [\n    {\n      "configurationId": ""\n    }\n  ]\n}'
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ]\n}")
val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit")
  .post(body)
  .addHeader("content-type", "application/json")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'POST',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit',
  headers: {
    'content-type': 'application/json'
  }
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.write(JSON.stringify({content: '', mentions: [{configurationId: ''}]}));
req.end();
const request = require('request');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit',
  headers: {'content-type': 'application/json'},
  body: {content: '', mentions: [{configurationId: ''}]},
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('POST', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit');

req.headers({
  'content-type': 'application/json'
});

req.type('json');
req.send({
  content: '',
  mentions: [
    {
      configurationId: ''
    }
  ]
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit',
  headers: {'content-type': 'application/json'},
  data: {content: '', mentions: [{configurationId: ''}]}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"content":"","mentions":[{"configurationId":""}]}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"content": @"",
                              @"mentions": @[ @{ @"configurationId": @"" } ] };

NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ]\n}" in

Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => json_encode([
    'content' => '',
    'mentions' => [
        [
                'configurationId' => ''
        ]
    ]
  ]),
  CURLOPT_HTTPHEADER => [
    "content-type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('POST', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit', [
  'body' => '{
  "content": "",
  "mentions": [
    {
      "configurationId": ""
    }
  ]
}',
  'headers' => [
    'content-type' => 'application/json',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$request->setContentType('application/json');
$request->setBody(json_encode([
  'content' => '',
  'mentions' => [
    [
        'configurationId' => ''
    ]
  ]
]));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
append(json_encode([
  'content' => '',
  'mentions' => [
    [
        'configurationId' => ''
    ]
  ]
]));
$request->setRequestUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit');
$request->setRequestMethod('POST');
$request->setBody($body);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "content": "",
  "mentions": [
    {
      "configurationId": ""
    }
  ]
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "content": "",
  "mentions": [
    {
      "configurationId": ""
    }
  ]
}'
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = "{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ]\n}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit"

payload = {
    "content": "",
    "mentions": [{ "configurationId": "" }]
}
headers = {"content-type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit"

payload <- "{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ]\n}"

encode <- "json"

response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ]\n}"

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/json'}
)

response = conn.post('/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit') do |req|
  req.body = "{\n  \"content\": \"\",\n  \"mentions\": [\n    {\n      \"configurationId\": \"\"\n    }\n  ]\n}"
end

puts response.status
puts response.body
use serde_json::json;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit";

    let payload = json!({
        "content": "",
        "mentions": (json!({"configurationId": ""}))
    });

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("content-type", "application/json".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.post(url)
        .headers(headers)
        .json(&payload)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request POST \
  --url {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit \
  --header 'content-type: application/json' \
  --data '{
  "content": "",
  "mentions": [
    {
      "configurationId": ""
    }
  ]
}'
echo '{
  "content": "",
  "mentions": [
    {
      "configurationId": ""
    }
  ]
}' |  \
  http POST {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit \
  content-type:application/json
wget --quiet \
  --method POST \
  --header 'content-type: application/json' \
  --body-data '{\n  "content": "",\n  "mentions": [\n    {\n      "configurationId": ""\n    }\n  ]\n}' \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit
import Foundation

let headers = ["content-type": "application/json"]
let parameters = [
  "content": "",
  "mentions": [["configurationId": ""]]
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/edit")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
GET Get a conversation
{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId
QUERY PARAMS

wId
cId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId"

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/assistant/conversations/:cId HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId"))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/assistant/conversations/:cId',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId');
$request->setMethod(HTTP_METH_GET);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/assistant/conversations/:cId")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId"

response = requests.get(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId"

response <- VERB("GET", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/assistant/conversations/:cId') do |req|
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId";

    let client = reqwest::Client::new();
    let response = client.get(url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId
http GET {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId
wget --quiet \
  --method GET \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "conversation": {
    "id": 67890,
    "created": 1625097600,
    "sId": "3d8f6a2c1b",
    "title": "Customer Inquiry #1234",
    "visibility": "private"
  }
}
GET Get events for a message
{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events
QUERY PARAMS

wId
cId
mId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events"

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events"))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events');
$request->setMethod(HTTP_METH_GET);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events"

response = requests.get(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events"

response <- VERB("GET", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events') do |req|
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events";

    let client = reqwest::Client::new();
    let response = client.get(url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events
http GET {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events
wget --quiet \
  --method GET \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/events")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
GET Get the events for a conversation
{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events
QUERY PARAMS

wId
cId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events"

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/assistant/conversations/:cId/events HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events"))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/events',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events');
$request->setMethod(HTTP_METH_GET);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/events")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events"

response = requests.get(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events"

response <- VERB("GET", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/events') do |req|
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events";

    let client = reqwest::Client::new();
    let response = client.get(url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events
http GET {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events
wget --quiet \
  --method GET \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/events")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
PATCH Mark a conversation as read
{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId
QUERY PARAMS

wId
cId
BODY json

{
  "read": false
}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "PATCH");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n  \"read\": false\n}");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/patch "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId" {:content-type :json
                                                                                        :form-params {:read false}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId"
headers = HTTP::Headers{
  "content-type" => "application/json"
}
reqBody = "{\n  \"read\": false\n}"

response = HTTP::Client.patch url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Patch,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId"),
    Content = new StringContent("{\n  \"read\": false\n}")
    {
        Headers =
        {
            ContentType = new MediaTypeHeaderValue("application/json")
        }
    }
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId");
var request = new RestRequest("", Method.Patch);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n  \"read\": false\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId"

	payload := strings.NewReader("{\n  \"read\": false\n}")

	req, _ := http.NewRequest("PATCH", url, payload)

	req.Header.Add("content-type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
PATCH /baseUrl/api/v1/w/:wId/assistant/conversations/:cId HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 19

{
  "read": false
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("PATCH", "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId")
  .setHeader("content-type", "application/json")
  .setBody("{\n  \"read\": false\n}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId"))
    .header("content-type", "application/json")
    .method("PATCH", HttpRequest.BodyPublishers.ofString("{\n  \"read\": false\n}"))
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n  \"read\": false\n}");
Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId")
  .patch(body)
  .addHeader("content-type", "application/json")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.patch("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId")
  .header("content-type", "application/json")
  .body("{\n  \"read\": false\n}")
  .asString();
const data = JSON.stringify({
  read: false
});

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('PATCH', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId');
xhr.setRequestHeader('content-type', 'application/json');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'PATCH',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId',
  headers: {'content-type': 'application/json'},
  data: {read: false}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId';
const options = {
  method: 'PATCH',
  headers: {'content-type': 'application/json'},
  body: '{"read":false}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId',
  method: 'PATCH',
  headers: {
    'content-type': 'application/json'
  },
  processData: false,
  data: '{\n  "read": false\n}'
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n  \"read\": false\n}")
val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId")
  .patch(body)
  .addHeader("content-type", "application/json")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'PATCH',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/assistant/conversations/:cId',
  headers: {
    'content-type': 'application/json'
  }
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.write(JSON.stringify({read: false}));
req.end();
const request = require('request');

const options = {
  method: 'PATCH',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId',
  headers: {'content-type': 'application/json'},
  body: {read: false},
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('PATCH', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId');

req.headers({
  'content-type': 'application/json'
});

req.type('json');
req.send({
  read: false
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'PATCH',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId',
  headers: {'content-type': 'application/json'},
  data: {read: false}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId';
const options = {
  method: 'PATCH',
  headers: {'content-type': 'application/json'},
  body: '{"read":false}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"read": @NO };

NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"PATCH"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n  \"read\": false\n}" in

Client.call ~headers ~body `PATCH uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "PATCH",
  CURLOPT_POSTFIELDS => json_encode([
    'read' => null
  ]),
  CURLOPT_HTTPHEADER => [
    "content-type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('PATCH', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId', [
  'body' => '{
  "read": false
}',
  'headers' => [
    'content-type' => 'application/json',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId');
$request->setMethod(HttpRequest::HTTP_METH_PATCH);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$request->setContentType('application/json');
$request->setBody(json_encode([
  'read' => null
]));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
append(json_encode([
  'read' => null
]));
$request->setRequestUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId');
$request->setRequestMethod('PATCH');
$request->setBody($body);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId' -Method PATCH -Headers $headers -ContentType 'application/json' -Body '{
  "read": false
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId' -Method PATCH -Headers $headers -ContentType 'application/json' -Body '{
  "read": false
}'
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = "{\n  \"read\": false\n}"

headers = { 'content-type': "application/json" }

conn.request("PATCH", "/baseUrl/api/v1/w/:wId/assistant/conversations/:cId", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId"

payload = { "read": False }
headers = {"content-type": "application/json"}

response = requests.patch(url, json=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId"

payload <- "{\n  \"read\": false\n}"

encode <- "json"

response <- VERB("PATCH", url, body = payload, content_type("application/json"), encode = encode)

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Patch.new(url)
request["content-type"] = 'application/json'
request.body = "{\n  \"read\": false\n}"

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/json'}
)

response = conn.patch('/baseUrl/api/v1/w/:wId/assistant/conversations/:cId') do |req|
  req.body = "{\n  \"read\": false\n}"
end

puts response.status
puts response.body
use std::str::FromStr;
use serde_json::json;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId";

    let payload = json!({"read": false});

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("content-type", "application/json".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.request(reqwest::Method::from_str("PATCH").unwrap(), url)
        .headers(headers)
        .json(&payload)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request PATCH \
  --url {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId \
  --header 'content-type: application/json' \
  --data '{
  "read": false
}'
echo '{
  "read": false
}' |  \
  http PATCH {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId \
  content-type:application/json
wget --quiet \
  --method PATCH \
  --header 'content-type: application/json' \
  --body-data '{\n  "read": false\n}' \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId
import Foundation

let headers = ["content-type": "application/json"]
let parameters = ["read": false] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "PATCH"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
POST Validate an action in a conversation message
{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action
QUERY PARAMS

wId
cId
mId
BODY json

{
  "actionId": "",
  "approved": false
}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n  \"actionId\": \"\",\n  \"approved\": false\n}");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/post "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action" {:content-type :json
                                                                                                                     :form-params {:actionId ""
                                                                                                                                   :approved false}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action"
headers = HTTP::Headers{
  "content-type" => "application/json"
}
reqBody = "{\n  \"actionId\": \"\",\n  \"approved\": false\n}"

response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Post,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action"),
    Content = new StringContent("{\n  \"actionId\": \"\",\n  \"approved\": false\n}")
    {
        Headers =
        {
            ContentType = new MediaTypeHeaderValue("application/json")
        }
    }
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n  \"actionId\": \"\",\n  \"approved\": false\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action"

	payload := strings.NewReader("{\n  \"actionId\": \"\",\n  \"approved\": false\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("content-type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
POST /baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 41

{
  "actionId": "",
  "approved": false
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action")
  .setHeader("content-type", "application/json")
  .setBody("{\n  \"actionId\": \"\",\n  \"approved\": false\n}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action"))
    .header("content-type", "application/json")
    .method("POST", HttpRequest.BodyPublishers.ofString("{\n  \"actionId\": \"\",\n  \"approved\": false\n}"))
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n  \"actionId\": \"\",\n  \"approved\": false\n}");
Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action")
  .post(body)
  .addHeader("content-type", "application/json")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action")
  .header("content-type", "application/json")
  .body("{\n  \"actionId\": \"\",\n  \"approved\": false\n}")
  .asString();
const data = JSON.stringify({
  actionId: '',
  approved: false
});

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('POST', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action');
xhr.setRequestHeader('content-type', 'application/json');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action',
  headers: {'content-type': 'application/json'},
  data: {actionId: '', approved: false}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"actionId":"","approved":false}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action',
  method: 'POST',
  headers: {
    'content-type': 'application/json'
  },
  processData: false,
  data: '{\n  "actionId": "",\n  "approved": false\n}'
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n  \"actionId\": \"\",\n  \"approved\": false\n}")
val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action")
  .post(body)
  .addHeader("content-type", "application/json")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'POST',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action',
  headers: {
    'content-type': 'application/json'
  }
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.write(JSON.stringify({actionId: '', approved: false}));
req.end();
const request = require('request');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action',
  headers: {'content-type': 'application/json'},
  body: {actionId: '', approved: false},
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('POST', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action');

req.headers({
  'content-type': 'application/json'
});

req.type('json');
req.send({
  actionId: '',
  approved: false
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action',
  headers: {'content-type': 'application/json'},
  data: {actionId: '', approved: false}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"actionId":"","approved":false}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"actionId": @"",
                              @"approved": @NO };

NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n  \"actionId\": \"\",\n  \"approved\": false\n}" in

Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => json_encode([
    'actionId' => '',
    'approved' => null
  ]),
  CURLOPT_HTTPHEADER => [
    "content-type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('POST', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action', [
  'body' => '{
  "actionId": "",
  "approved": false
}',
  'headers' => [
    'content-type' => 'application/json',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$request->setContentType('application/json');
$request->setBody(json_encode([
  'actionId' => '',
  'approved' => null
]));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
append(json_encode([
  'actionId' => '',
  'approved' => null
]));
$request->setRequestUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action');
$request->setRequestMethod('POST');
$request->setBody($body);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "actionId": "",
  "approved": false
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "actionId": "",
  "approved": false
}'
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = "{\n  \"actionId\": \"\",\n  \"approved\": false\n}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action"

payload = {
    "actionId": "",
    "approved": False
}
headers = {"content-type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action"

payload <- "{\n  \"actionId\": \"\",\n  \"approved\": false\n}"

encode <- "json"

response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\n  \"actionId\": \"\",\n  \"approved\": false\n}"

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/json'}
)

response = conn.post('/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action') do |req|
  req.body = "{\n  \"actionId\": \"\",\n  \"approved\": false\n}"
end

puts response.status
puts response.body
use serde_json::json;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action";

    let payload = json!({
        "actionId": "",
        "approved": false
    });

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("content-type", "application/json".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.post(url)
        .headers(headers)
        .json(&payload)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request POST \
  --url {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action \
  --header 'content-type: application/json' \
  --data '{
  "actionId": "",
  "approved": false
}'
echo '{
  "actionId": "",
  "approved": false
}' |  \
  http POST {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action \
  content-type:application/json
wget --quiet \
  --method POST \
  --header 'content-type: application/json' \
  --body-data '{\n  "actionId": "",\n  "approved": false\n}' \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action
import Foundation

let headers = ["content-type": "application/json"]
let parameters = [
  "actionId": "",
  "approved": false
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/validate-action")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
DELETE Delete a document from a data source
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId
QUERY PARAMS

wId
spaceId
dsId
documentId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "DELETE");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/delete "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId"

response = HTTP::Client.delete url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Delete,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId");
var request = new RestRequest("", Method.Delete);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId"

	req, _ := http.NewRequest("DELETE", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
DELETE /baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("DELETE", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId"))
    .method("DELETE", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId")
  .delete(null)
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.delete("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('DELETE', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'DELETE',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId';
const options = {method: 'DELETE'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId',
  method: 'DELETE',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId")
  .delete(null)
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'DELETE',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'DELETE',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('DELETE', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'DELETE',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId';
const options = {method: 'DELETE'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"DELETE"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId" in

Client.call `DELETE uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "DELETE",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('DELETE', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId');
$request->setMethod(HTTP_METH_DELETE);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId');
$request->setRequestMethod('DELETE');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId' -Method DELETE 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId' -Method DELETE 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("DELETE", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId"

response = requests.delete(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId"

response <- VERB("DELETE", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.delete('/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId') do |req|
end

puts response.status
puts response.body
use std::str::FromStr;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId";

    let client = reqwest::Client::new();
    let response = client.request(reqwest::Method::from_str("DELETE").unwrap(), url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request DELETE \
  --url {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId
http DELETE {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId
wget --quiet \
  --method DELETE \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "DELETE"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
DELETE Delete a row
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId
QUERY PARAMS

wId
spaceId
dsId
tId
rId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "DELETE");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/delete "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId"

response = HTTP::Client.delete url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Delete,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId");
var request = new RestRequest("", Method.Delete);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId"

	req, _ := http.NewRequest("DELETE", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
DELETE /baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("DELETE", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId"))
    .method("DELETE", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId")
  .delete(null)
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.delete("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('DELETE', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'DELETE',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId';
const options = {method: 'DELETE'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId',
  method: 'DELETE',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId")
  .delete(null)
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'DELETE',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'DELETE',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('DELETE', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'DELETE',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId';
const options = {method: 'DELETE'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"DELETE"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId" in

Client.call `DELETE uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "DELETE",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('DELETE', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId');
$request->setMethod(HTTP_METH_DELETE);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId');
$request->setRequestMethod('DELETE');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId' -Method DELETE 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId' -Method DELETE 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("DELETE", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId"

response = requests.delete(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId"

response <- VERB("DELETE", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.delete('/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId') do |req|
end

puts response.status
puts response.body
use std::str::FromStr;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId";

    let client = reqwest::Client::new();
    let response = client.request(reqwest::Method::from_str("DELETE").unwrap(), url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request DELETE \
  --url {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId
http DELETE {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId
wget --quiet \
  --method DELETE \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "DELETE"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
DELETE Delete a table
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId
QUERY PARAMS

wId
spaceId
dsId
tId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "DELETE");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/delete "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId"

response = HTTP::Client.delete url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Delete,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId");
var request = new RestRequest("", Method.Delete);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId"

	req, _ := http.NewRequest("DELETE", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
DELETE /baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("DELETE", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId"))
    .method("DELETE", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId")
  .delete(null)
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.delete("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('DELETE', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'DELETE',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId';
const options = {method: 'DELETE'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId',
  method: 'DELETE',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId")
  .delete(null)
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'DELETE',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'DELETE',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('DELETE', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'DELETE',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId';
const options = {method: 'DELETE'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"DELETE"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId" in

Client.call `DELETE uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "DELETE",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('DELETE', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId');
$request->setMethod(HTTP_METH_DELETE);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId');
$request->setRequestMethod('DELETE');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId' -Method DELETE 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId' -Method DELETE 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("DELETE", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId"

response = requests.delete(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId"

response <- VERB("DELETE", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.delete('/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId') do |req|
end

puts response.status
puts response.body
use std::str::FromStr;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId";

    let client = reqwest::Client::new();
    let response = client.request(reqwest::Method::from_str("DELETE").unwrap(), url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request DELETE \
  --url {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId
http DELETE {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId
wget --quiet \
  --method DELETE \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "DELETE"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
GET Get a row
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId
QUERY PARAMS

wId
spaceId
dsId
tId
rId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId"

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId"))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId');
$request->setMethod(HTTP_METH_GET);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId"

response = requests.get(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId"

response <- VERB("GET", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId') do |req|
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId";

    let client = reqwest::Client::new();
    let response = client.get(url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId
http GET {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId
wget --quiet \
  --method GET \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows/:rId")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "id": 12345,
  "createdAt": 1625097600,
  "name": "Customer Knowledge Base",
  "description": "Contains all customer-related information and FAQs",
  "dustAPIProjectId": "5e9d8c7b6a",
  "connectorId": "1f3e5d7c9b",
  "connectorProvider": "webcrawler",
  "assistantDefaultSelected": true
}
GET Get a table
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId
QUERY PARAMS

wId
spaceId
dsId
tId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId"

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId"))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId');
$request->setMethod(HTTP_METH_GET);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId"

response = requests.get(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId"

response <- VERB("GET", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId') do |req|
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId";

    let client = reqwest::Client::new();
    let response = client.get(url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId
http GET {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId
wget --quiet \
  --method GET \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "name": "Roi data",
  "title": "ROI Data",
  "table_id": "1234f4567c",
  "description": "roi data for Q1",
  "mime_type": "text/csv",
  "timestamp": 1732810375150,
  "parent_id": "1234f4567c",
  "parents": [
    "1234f4567c"
  ]
}
GET Get data sources
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources
QUERY PARAMS

wId
spaceId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources"

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources"))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources');
$request->setMethod(HTTP_METH_GET);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources"

response = requests.get(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources"

response <- VERB("GET", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources') do |req|
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources";

    let client = reqwest::Client::new();
    let response = client.get(url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources
http GET {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources
wget --quiet \
  --method GET \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
GET Get documents
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents
QUERY PARAMS

wId
spaceId
dsId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents"

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents"))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents');
$request->setMethod(HTTP_METH_GET);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents"

response = requests.get(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents"

response <- VERB("GET", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents') do |req|
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents";

    let client = reqwest::Client::new();
    let response = client.get(url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents
http GET {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents
wget --quiet \
  --method GET \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
GET Get tables
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables
QUERY PARAMS

wId
spaceId
dsId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables"

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables"))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables');
$request->setMethod(HTTP_METH_GET);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables"

response = requests.get(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables"

response <- VERB("GET", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables') do |req|
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables";

    let client = reqwest::Client::new();
    let response = client.get(url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables
http GET {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables
wget --quiet \
  --method GET \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

[
  {
    "name": "Roi data",
    "title": "ROI Data",
    "table_id": "1234f4567c",
    "description": "roi data for Q1",
    "mime_type": "text/csv",
    "timestamp": 1732810375150,
    "parent_id": "1234f4567c",
    "parents": [
      "1234f4567c"
    ]
  }
]
GET List rows
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows
QUERY PARAMS

wId
spaceId
dsId
tId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows"

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows"))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows');
$request->setMethod(HTTP_METH_GET);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows"

response = requests.get(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows"

response <- VERB("GET", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows') do |req|
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows";

    let client = reqwest::Client::new();
    let response = client.get(url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows
http GET {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows
wget --quiet \
  --method GET \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

[
  {
    "id": 12345,
    "createdAt": 1625097600,
    "name": "Customer Knowledge Base",
    "description": "Contains all customer-related information and FAQs",
    "dustAPIProjectId": "5e9d8c7b6a",
    "connectorId": "1f3e5d7c9b",
    "connectorProvider": "webcrawler",
    "assistantDefaultSelected": true
  }
]
GET Retrieve a document from a data source
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId
QUERY PARAMS

wId
spaceId
dsId
documentId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId"

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId"))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId');
$request->setMethod(HTTP_METH_GET);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId"

response = requests.get(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId"

response <- VERB("GET", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId') do |req|
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId";

    let client = reqwest::Client::new();
    let response = client.get(url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId
http GET {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId
wget --quiet \
  --method GET \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "document": {
    "data_source_id": "3b7d9f1e5a",
    "created": 1625097600,
    "document_id": "2c4a6e8d0f",
    "title": "Customer Support FAQ",
    "mime_type": "text/md",
    "timestamp": 1625097600,
    "tags": [
      "customer_support",
      "faq"
    ],
    "parent_id": "1234f4567c",
    "parents": [
      "7b9d1f3e5a",
      "2c4a6e8d0f"
    ],
    "source_url": "https://example.com/support/article1",
    "hash": "a1b2c3d4e5",
    "text_size": 1024,
    "chunk_count": 5,
    "chunks": [
      {
        "chunk_id": "9f1d3b5a7c",
        "text": "This is the first chunk of the document.",
        "embedding": [
          0.1,
          0.2,
          0.3,
          0.4
        ]
      },
      {
        "chunk_id": "4a2c6e8b0d",
        "text": "This is the second chunk of the document.",
        "embedding": [
          0.5,
          0.6,
          0.7,
          0.8
        ]
      }
    ],
    "text": "This is the full text content of the document. It contains multiple paragraphs and covers various topics related to customer support.",
    "token_count": 150
  }
}
GET Search the data source
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search
QUERY PARAMS

query
top_k
full_text
wId
spaceId
dsId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text=");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search" {:query-params {:query ""
                                                                                                                  :top_k ""
                                                                                                                  :full_text ""}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text="

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text="),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text=");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text="

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text= HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text=")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text="))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text=")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text=")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text=');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search',
  params: {query: '', top_k: '', full_text: ''}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text=';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text=',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text=")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text=',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search',
  qs: {query: '', top_k: '', full_text: ''}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search');

req.query({
  query: '',
  top_k: '',
  full_text: ''
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search',
  params: {query: '', top_k: '', full_text: ''}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text=';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text="]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text=" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text=",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text=');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search');
$request->setMethod(HTTP_METH_GET);

$request->setQueryData([
  'query' => '',
  'top_k' => '',
  'full_text' => ''
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search');
$request->setRequestMethod('GET');
$request->setQuery(new http\QueryString([
  'query' => '',
  'top_k' => '',
  'full_text' => ''
]));

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text=' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text=' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text=")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search"

querystring = {"query":"","top_k":"","full_text":""}

response = requests.get(url, params=querystring)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search"

queryString <- list(
  query = "",
  top_k = "",
  full_text = ""
)

response <- VERB("GET", url, query = queryString, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text=")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search') do |req|
  req.params['query'] = ''
  req.params['top_k'] = ''
  req.params['full_text'] = ''
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search";

    let querystring = [
        ("query", ""),
        ("top_k", ""),
        ("full_text", ""),
    ];

    let client = reqwest::Client::new();
    let response = client.get(url)
        .query(&querystring)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text='
http GET '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text='
wget --quiet \
  --method GET \
  --output-document \
  - '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text='
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/search?query=&top_k=&full_text=")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
POST Update the parents of a document
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents
QUERY PARAMS

wId
spaceId
dsId
documentId
BODY json

{
  "parent_id": "",
  "parents": []
}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n  \"parent_id\": \"\",\n  \"parents\": []\n}");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/post "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents" {:content-type :json
                                                                                                                           :form-params {:parent_id ""
                                                                                                                                         :parents []}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents"
headers = HTTP::Headers{
  "content-type" => "application/json"
}
reqBody = "{\n  \"parent_id\": \"\",\n  \"parents\": []\n}"

response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Post,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents"),
    Content = new StringContent("{\n  \"parent_id\": \"\",\n  \"parents\": []\n}")
    {
        Headers =
        {
            ContentType = new MediaTypeHeaderValue("application/json")
        }
    }
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n  \"parent_id\": \"\",\n  \"parents\": []\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents"

	payload := strings.NewReader("{\n  \"parent_id\": \"\",\n  \"parents\": []\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("content-type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
POST /baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 38

{
  "parent_id": "",
  "parents": []
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents")
  .setHeader("content-type", "application/json")
  .setBody("{\n  \"parent_id\": \"\",\n  \"parents\": []\n}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents"))
    .header("content-type", "application/json")
    .method("POST", HttpRequest.BodyPublishers.ofString("{\n  \"parent_id\": \"\",\n  \"parents\": []\n}"))
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n  \"parent_id\": \"\",\n  \"parents\": []\n}");
Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents")
  .post(body)
  .addHeader("content-type", "application/json")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents")
  .header("content-type", "application/json")
  .body("{\n  \"parent_id\": \"\",\n  \"parents\": []\n}")
  .asString();
const data = JSON.stringify({
  parent_id: '',
  parents: []
});

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('POST', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents');
xhr.setRequestHeader('content-type', 'application/json');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents',
  headers: {'content-type': 'application/json'},
  data: {parent_id: '', parents: []}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"parent_id":"","parents":[]}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents',
  method: 'POST',
  headers: {
    'content-type': 'application/json'
  },
  processData: false,
  data: '{\n  "parent_id": "",\n  "parents": []\n}'
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n  \"parent_id\": \"\",\n  \"parents\": []\n}")
val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents")
  .post(body)
  .addHeader("content-type", "application/json")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'POST',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents',
  headers: {
    'content-type': 'application/json'
  }
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.write(JSON.stringify({parent_id: '', parents: []}));
req.end();
const request = require('request');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents',
  headers: {'content-type': 'application/json'},
  body: {parent_id: '', parents: []},
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('POST', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents');

req.headers({
  'content-type': 'application/json'
});

req.type('json');
req.send({
  parent_id: '',
  parents: []
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents',
  headers: {'content-type': 'application/json'},
  data: {parent_id: '', parents: []}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"parent_id":"","parents":[]}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"parent_id": @"",
                              @"parents": @[  ] };

NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n  \"parent_id\": \"\",\n  \"parents\": []\n}" in

Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => json_encode([
    'parent_id' => '',
    'parents' => [
        
    ]
  ]),
  CURLOPT_HTTPHEADER => [
    "content-type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('POST', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents', [
  'body' => '{
  "parent_id": "",
  "parents": []
}',
  'headers' => [
    'content-type' => 'application/json',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$request->setContentType('application/json');
$request->setBody(json_encode([
  'parent_id' => '',
  'parents' => [
    
  ]
]));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
append(json_encode([
  'parent_id' => '',
  'parents' => [
    
  ]
]));
$request->setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents');
$request->setRequestMethod('POST');
$request->setBody($body);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "parent_id": "",
  "parents": []
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "parent_id": "",
  "parents": []
}'
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = "{\n  \"parent_id\": \"\",\n  \"parents\": []\n}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents"

payload = {
    "parent_id": "",
    "parents": []
}
headers = {"content-type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents"

payload <- "{\n  \"parent_id\": \"\",\n  \"parents\": []\n}"

encode <- "json"

response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\n  \"parent_id\": \"\",\n  \"parents\": []\n}"

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/json'}
)

response = conn.post('/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents') do |req|
  req.body = "{\n  \"parent_id\": \"\",\n  \"parents\": []\n}"
end

puts response.status
puts response.body
use serde_json::json;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents";

    let payload = json!({
        "parent_id": "",
        "parents": ()
    });

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("content-type", "application/json".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.post(url)
        .headers(headers)
        .json(&payload)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request POST \
  --url {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents \
  --header 'content-type: application/json' \
  --data '{
  "parent_id": "",
  "parents": []
}'
echo '{
  "parent_id": "",
  "parents": []
}' |  \
  http POST {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents \
  content-type:application/json
wget --quiet \
  --method POST \
  --header 'content-type: application/json' \
  --body-data '{\n  "parent_id": "",\n  "parents": []\n}' \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents
import Foundation

let headers = ["content-type": "application/json"]
let parameters = [
  "parent_id": "",
  "parents": []
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId/parents")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
POST Upsert a document in a data source
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId
QUERY PARAMS

wId
spaceId
dsId
documentId
BODY json

{
  "title": "",
  "mime_type": "",
  "text": "",
  "section": {
    "prefix": "",
    "content": "",
    "sections": []
  },
  "source_url": "",
  "tags": [],
  "timestamp": "",
  "light_document_output": false,
  "async": false,
  "upsert_context": {}
}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n  \"title\": \"\",\n  \"mime_type\": \"\",\n  \"text\": \"\",\n  \"section\": {\n    \"prefix\": \"\",\n    \"content\": \"\",\n    \"sections\": []\n  },\n  \"source_url\": \"\",\n  \"tags\": [],\n  \"timestamp\": \"\",\n  \"light_document_output\": false,\n  \"async\": false,\n  \"upsert_context\": {}\n}");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/post "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId" {:content-type :json
                                                                                                                   :form-params {:title ""
                                                                                                                                 :mime_type ""
                                                                                                                                 :text ""
                                                                                                                                 :section {:prefix ""
                                                                                                                                           :content ""
                                                                                                                                           :sections []}
                                                                                                                                 :source_url ""
                                                                                                                                 :tags []
                                                                                                                                 :timestamp ""
                                                                                                                                 :light_document_output false
                                                                                                                                 :async false
                                                                                                                                 :upsert_context {}}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId"
headers = HTTP::Headers{
  "content-type" => "application/json"
}
reqBody = "{\n  \"title\": \"\",\n  \"mime_type\": \"\",\n  \"text\": \"\",\n  \"section\": {\n    \"prefix\": \"\",\n    \"content\": \"\",\n    \"sections\": []\n  },\n  \"source_url\": \"\",\n  \"tags\": [],\n  \"timestamp\": \"\",\n  \"light_document_output\": false,\n  \"async\": false,\n  \"upsert_context\": {}\n}"

response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Post,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId"),
    Content = new StringContent("{\n  \"title\": \"\",\n  \"mime_type\": \"\",\n  \"text\": \"\",\n  \"section\": {\n    \"prefix\": \"\",\n    \"content\": \"\",\n    \"sections\": []\n  },\n  \"source_url\": \"\",\n  \"tags\": [],\n  \"timestamp\": \"\",\n  \"light_document_output\": false,\n  \"async\": false,\n  \"upsert_context\": {}\n}")
    {
        Headers =
        {
            ContentType = new MediaTypeHeaderValue("application/json")
        }
    }
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n  \"title\": \"\",\n  \"mime_type\": \"\",\n  \"text\": \"\",\n  \"section\": {\n    \"prefix\": \"\",\n    \"content\": \"\",\n    \"sections\": []\n  },\n  \"source_url\": \"\",\n  \"tags\": [],\n  \"timestamp\": \"\",\n  \"light_document_output\": false,\n  \"async\": false,\n  \"upsert_context\": {}\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId"

	payload := strings.NewReader("{\n  \"title\": \"\",\n  \"mime_type\": \"\",\n  \"text\": \"\",\n  \"section\": {\n    \"prefix\": \"\",\n    \"content\": \"\",\n    \"sections\": []\n  },\n  \"source_url\": \"\",\n  \"tags\": [],\n  \"timestamp\": \"\",\n  \"light_document_output\": false,\n  \"async\": false,\n  \"upsert_context\": {}\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("content-type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
POST /baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 255

{
  "title": "",
  "mime_type": "",
  "text": "",
  "section": {
    "prefix": "",
    "content": "",
    "sections": []
  },
  "source_url": "",
  "tags": [],
  "timestamp": "",
  "light_document_output": false,
  "async": false,
  "upsert_context": {}
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId")
  .setHeader("content-type", "application/json")
  .setBody("{\n  \"title\": \"\",\n  \"mime_type\": \"\",\n  \"text\": \"\",\n  \"section\": {\n    \"prefix\": \"\",\n    \"content\": \"\",\n    \"sections\": []\n  },\n  \"source_url\": \"\",\n  \"tags\": [],\n  \"timestamp\": \"\",\n  \"light_document_output\": false,\n  \"async\": false,\n  \"upsert_context\": {}\n}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId"))
    .header("content-type", "application/json")
    .method("POST", HttpRequest.BodyPublishers.ofString("{\n  \"title\": \"\",\n  \"mime_type\": \"\",\n  \"text\": \"\",\n  \"section\": {\n    \"prefix\": \"\",\n    \"content\": \"\",\n    \"sections\": []\n  },\n  \"source_url\": \"\",\n  \"tags\": [],\n  \"timestamp\": \"\",\n  \"light_document_output\": false,\n  \"async\": false,\n  \"upsert_context\": {}\n}"))
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n  \"title\": \"\",\n  \"mime_type\": \"\",\n  \"text\": \"\",\n  \"section\": {\n    \"prefix\": \"\",\n    \"content\": \"\",\n    \"sections\": []\n  },\n  \"source_url\": \"\",\n  \"tags\": [],\n  \"timestamp\": \"\",\n  \"light_document_output\": false,\n  \"async\": false,\n  \"upsert_context\": {}\n}");
Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId")
  .post(body)
  .addHeader("content-type", "application/json")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId")
  .header("content-type", "application/json")
  .body("{\n  \"title\": \"\",\n  \"mime_type\": \"\",\n  \"text\": \"\",\n  \"section\": {\n    \"prefix\": \"\",\n    \"content\": \"\",\n    \"sections\": []\n  },\n  \"source_url\": \"\",\n  \"tags\": [],\n  \"timestamp\": \"\",\n  \"light_document_output\": false,\n  \"async\": false,\n  \"upsert_context\": {}\n}")
  .asString();
const data = JSON.stringify({
  title: '',
  mime_type: '',
  text: '',
  section: {
    prefix: '',
    content: '',
    sections: []
  },
  source_url: '',
  tags: [],
  timestamp: '',
  light_document_output: false,
  async: false,
  upsert_context: {}
});

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('POST', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId');
xhr.setRequestHeader('content-type', 'application/json');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId',
  headers: {'content-type': 'application/json'},
  data: {
    title: '',
    mime_type: '',
    text: '',
    section: {prefix: '', content: '', sections: []},
    source_url: '',
    tags: [],
    timestamp: '',
    light_document_output: false,
    async: false,
    upsert_context: {}
  }
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"title":"","mime_type":"","text":"","section":{"prefix":"","content":"","sections":[]},"source_url":"","tags":[],"timestamp":"","light_document_output":false,"async":false,"upsert_context":{}}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId',
  method: 'POST',
  headers: {
    'content-type': 'application/json'
  },
  processData: false,
  data: '{\n  "title": "",\n  "mime_type": "",\n  "text": "",\n  "section": {\n    "prefix": "",\n    "content": "",\n    "sections": []\n  },\n  "source_url": "",\n  "tags": [],\n  "timestamp": "",\n  "light_document_output": false,\n  "async": false,\n  "upsert_context": {}\n}'
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n  \"title\": \"\",\n  \"mime_type\": \"\",\n  \"text\": \"\",\n  \"section\": {\n    \"prefix\": \"\",\n    \"content\": \"\",\n    \"sections\": []\n  },\n  \"source_url\": \"\",\n  \"tags\": [],\n  \"timestamp\": \"\",\n  \"light_document_output\": false,\n  \"async\": false,\n  \"upsert_context\": {}\n}")
val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId")
  .post(body)
  .addHeader("content-type", "application/json")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'POST',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId',
  headers: {
    'content-type': 'application/json'
  }
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.write(JSON.stringify({
  title: '',
  mime_type: '',
  text: '',
  section: {prefix: '', content: '', sections: []},
  source_url: '',
  tags: [],
  timestamp: '',
  light_document_output: false,
  async: false,
  upsert_context: {}
}));
req.end();
const request = require('request');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId',
  headers: {'content-type': 'application/json'},
  body: {
    title: '',
    mime_type: '',
    text: '',
    section: {prefix: '', content: '', sections: []},
    source_url: '',
    tags: [],
    timestamp: '',
    light_document_output: false,
    async: false,
    upsert_context: {}
  },
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('POST', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId');

req.headers({
  'content-type': 'application/json'
});

req.type('json');
req.send({
  title: '',
  mime_type: '',
  text: '',
  section: {
    prefix: '',
    content: '',
    sections: []
  },
  source_url: '',
  tags: [],
  timestamp: '',
  light_document_output: false,
  async: false,
  upsert_context: {}
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId',
  headers: {'content-type': 'application/json'},
  data: {
    title: '',
    mime_type: '',
    text: '',
    section: {prefix: '', content: '', sections: []},
    source_url: '',
    tags: [],
    timestamp: '',
    light_document_output: false,
    async: false,
    upsert_context: {}
  }
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"title":"","mime_type":"","text":"","section":{"prefix":"","content":"","sections":[]},"source_url":"","tags":[],"timestamp":"","light_document_output":false,"async":false,"upsert_context":{}}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"title": @"",
                              @"mime_type": @"",
                              @"text": @"",
                              @"section": @{ @"prefix": @"", @"content": @"", @"sections": @[  ] },
                              @"source_url": @"",
                              @"tags": @[  ],
                              @"timestamp": @"",
                              @"light_document_output": @NO,
                              @"async": @NO,
                              @"upsert_context": @{  } };

NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n  \"title\": \"\",\n  \"mime_type\": \"\",\n  \"text\": \"\",\n  \"section\": {\n    \"prefix\": \"\",\n    \"content\": \"\",\n    \"sections\": []\n  },\n  \"source_url\": \"\",\n  \"tags\": [],\n  \"timestamp\": \"\",\n  \"light_document_output\": false,\n  \"async\": false,\n  \"upsert_context\": {}\n}" in

Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => json_encode([
    'title' => '',
    'mime_type' => '',
    'text' => '',
    'section' => [
        'prefix' => '',
        'content' => '',
        'sections' => [
                
        ]
    ],
    'source_url' => '',
    'tags' => [
        
    ],
    'timestamp' => '',
    'light_document_output' => null,
    'async' => null,
    'upsert_context' => [
        
    ]
  ]),
  CURLOPT_HTTPHEADER => [
    "content-type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('POST', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId', [
  'body' => '{
  "title": "",
  "mime_type": "",
  "text": "",
  "section": {
    "prefix": "",
    "content": "",
    "sections": []
  },
  "source_url": "",
  "tags": [],
  "timestamp": "",
  "light_document_output": false,
  "async": false,
  "upsert_context": {}
}',
  'headers' => [
    'content-type' => 'application/json',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$request->setContentType('application/json');
$request->setBody(json_encode([
  'title' => '',
  'mime_type' => '',
  'text' => '',
  'section' => [
    'prefix' => '',
    'content' => '',
    'sections' => [
        
    ]
  ],
  'source_url' => '',
  'tags' => [
    
  ],
  'timestamp' => '',
  'light_document_output' => null,
  'async' => null,
  'upsert_context' => [
    
  ]
]));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
append(json_encode([
  'title' => '',
  'mime_type' => '',
  'text' => '',
  'section' => [
    'prefix' => '',
    'content' => '',
    'sections' => [
        
    ]
  ],
  'source_url' => '',
  'tags' => [
    
  ],
  'timestamp' => '',
  'light_document_output' => null,
  'async' => null,
  'upsert_context' => [
    
  ]
]));
$request->setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId');
$request->setRequestMethod('POST');
$request->setBody($body);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "title": "",
  "mime_type": "",
  "text": "",
  "section": {
    "prefix": "",
    "content": "",
    "sections": []
  },
  "source_url": "",
  "tags": [],
  "timestamp": "",
  "light_document_output": false,
  "async": false,
  "upsert_context": {}
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "title": "",
  "mime_type": "",
  "text": "",
  "section": {
    "prefix": "",
    "content": "",
    "sections": []
  },
  "source_url": "",
  "tags": [],
  "timestamp": "",
  "light_document_output": false,
  "async": false,
  "upsert_context": {}
}'
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = "{\n  \"title\": \"\",\n  \"mime_type\": \"\",\n  \"text\": \"\",\n  \"section\": {\n    \"prefix\": \"\",\n    \"content\": \"\",\n    \"sections\": []\n  },\n  \"source_url\": \"\",\n  \"tags\": [],\n  \"timestamp\": \"\",\n  \"light_document_output\": false,\n  \"async\": false,\n  \"upsert_context\": {}\n}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId"

payload = {
    "title": "",
    "mime_type": "",
    "text": "",
    "section": {
        "prefix": "",
        "content": "",
        "sections": []
    },
    "source_url": "",
    "tags": [],
    "timestamp": "",
    "light_document_output": False,
    "async": False,
    "upsert_context": {}
}
headers = {"content-type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId"

payload <- "{\n  \"title\": \"\",\n  \"mime_type\": \"\",\n  \"text\": \"\",\n  \"section\": {\n    \"prefix\": \"\",\n    \"content\": \"\",\n    \"sections\": []\n  },\n  \"source_url\": \"\",\n  \"tags\": [],\n  \"timestamp\": \"\",\n  \"light_document_output\": false,\n  \"async\": false,\n  \"upsert_context\": {}\n}"

encode <- "json"

response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\n  \"title\": \"\",\n  \"mime_type\": \"\",\n  \"text\": \"\",\n  \"section\": {\n    \"prefix\": \"\",\n    \"content\": \"\",\n    \"sections\": []\n  },\n  \"source_url\": \"\",\n  \"tags\": [],\n  \"timestamp\": \"\",\n  \"light_document_output\": false,\n  \"async\": false,\n  \"upsert_context\": {}\n}"

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/json'}
)

response = conn.post('/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId') do |req|
  req.body = "{\n  \"title\": \"\",\n  \"mime_type\": \"\",\n  \"text\": \"\",\n  \"section\": {\n    \"prefix\": \"\",\n    \"content\": \"\",\n    \"sections\": []\n  },\n  \"source_url\": \"\",\n  \"tags\": [],\n  \"timestamp\": \"\",\n  \"light_document_output\": false,\n  \"async\": false,\n  \"upsert_context\": {}\n}"
end

puts response.status
puts response.body
use serde_json::json;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId";

    let payload = json!({
        "title": "",
        "mime_type": "",
        "text": "",
        "section": json!({
            "prefix": "",
            "content": "",
            "sections": ()
        }),
        "source_url": "",
        "tags": (),
        "timestamp": "",
        "light_document_output": false,
        "async": false,
        "upsert_context": json!({})
    });

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("content-type", "application/json".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.post(url)
        .headers(headers)
        .json(&payload)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request POST \
  --url {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId \
  --header 'content-type: application/json' \
  --data '{
  "title": "",
  "mime_type": "",
  "text": "",
  "section": {
    "prefix": "",
    "content": "",
    "sections": []
  },
  "source_url": "",
  "tags": [],
  "timestamp": "",
  "light_document_output": false,
  "async": false,
  "upsert_context": {}
}'
echo '{
  "title": "",
  "mime_type": "",
  "text": "",
  "section": {
    "prefix": "",
    "content": "",
    "sections": []
  },
  "source_url": "",
  "tags": [],
  "timestamp": "",
  "light_document_output": false,
  "async": false,
  "upsert_context": {}
}' |  \
  http POST {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId \
  content-type:application/json
wget --quiet \
  --method POST \
  --header 'content-type: application/json' \
  --body-data '{\n  "title": "",\n  "mime_type": "",\n  "text": "",\n  "section": {\n    "prefix": "",\n    "content": "",\n    "sections": []\n  },\n  "source_url": "",\n  "tags": [],\n  "timestamp": "",\n  "light_document_output": false,\n  "async": false,\n  "upsert_context": {}\n}' \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId
import Foundation

let headers = ["content-type": "application/json"]
let parameters = [
  "title": "",
  "mime_type": "",
  "text": "",
  "section": [
    "prefix": "",
    "content": "",
    "sections": []
  ],
  "source_url": "",
  "tags": [],
  "timestamp": "",
  "light_document_output": false,
  "async": false,
  "upsert_context": []
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/documents/:documentId")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "document": {
    "data_source_id": "3b7d9f1e5a",
    "created": 1625097600,
    "document_id": "2c4a6e8d0f",
    "title": "Customer Support FAQ",
    "mime_type": "text/md",
    "timestamp": 1625097600,
    "tags": [
      "customer_support",
      "faq"
    ],
    "parent_id": "1234f4567c",
    "parents": [
      "7b9d1f3e5a",
      "2c4a6e8d0f"
    ],
    "source_url": "https://example.com/support/article1",
    "hash": "a1b2c3d4e5",
    "text_size": 1024,
    "chunk_count": 5,
    "chunks": [
      {
        "chunk_id": "9f1d3b5a7c",
        "text": "This is the first chunk of the document.",
        "embedding": [
          0.1,
          0.2,
          0.3,
          0.4
        ]
      },
      {
        "chunk_id": "4a2c6e8b0d",
        "text": "This is the second chunk of the document.",
        "embedding": [
          0.5,
          0.6,
          0.7,
          0.8
        ]
      }
    ],
    "text": "This is the full text content of the document. It contains multiple paragraphs and covers various topics related to customer support.",
    "token_count": 150
  },
  "data_source": {
    "id": 12345,
    "createdAt": 1625097600,
    "name": "Customer Knowledge Base",
    "description": "Contains all customer-related information and FAQs",
    "dustAPIProjectId": "5e9d8c7b6a",
    "connectorId": "1f3e5d7c9b",
    "connectorProvider": "webcrawler",
    "assistantDefaultSelected": true
  }
}
POST Upsert a table
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables
QUERY PARAMS

wId
spaceId
dsId
BODY json

{
  "name": "",
  "title": "",
  "table_id": "",
  "description": "",
  "timestamp": "",
  "tags": [],
  "mime_type": ""
}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n  \"name\": \"\",\n  \"title\": \"\",\n  \"table_id\": \"\",\n  \"description\": \"\",\n  \"timestamp\": \"\",\n  \"tags\": [],\n  \"mime_type\": \"\"\n}");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/post "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables" {:content-type :json
                                                                                                    :form-params {:name ""
                                                                                                                  :title ""
                                                                                                                  :table_id ""
                                                                                                                  :description ""
                                                                                                                  :timestamp ""
                                                                                                                  :tags []
                                                                                                                  :mime_type ""}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables"
headers = HTTP::Headers{
  "content-type" => "application/json"
}
reqBody = "{\n  \"name\": \"\",\n  \"title\": \"\",\n  \"table_id\": \"\",\n  \"description\": \"\",\n  \"timestamp\": \"\",\n  \"tags\": [],\n  \"mime_type\": \"\"\n}"

response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Post,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables"),
    Content = new StringContent("{\n  \"name\": \"\",\n  \"title\": \"\",\n  \"table_id\": \"\",\n  \"description\": \"\",\n  \"timestamp\": \"\",\n  \"tags\": [],\n  \"mime_type\": \"\"\n}")
    {
        Headers =
        {
            ContentType = new MediaTypeHeaderValue("application/json")
        }
    }
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n  \"name\": \"\",\n  \"title\": \"\",\n  \"table_id\": \"\",\n  \"description\": \"\",\n  \"timestamp\": \"\",\n  \"tags\": [],\n  \"mime_type\": \"\"\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables"

	payload := strings.NewReader("{\n  \"name\": \"\",\n  \"title\": \"\",\n  \"table_id\": \"\",\n  \"description\": \"\",\n  \"timestamp\": \"\",\n  \"tags\": [],\n  \"mime_type\": \"\"\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("content-type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
POST /baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 122

{
  "name": "",
  "title": "",
  "table_id": "",
  "description": "",
  "timestamp": "",
  "tags": [],
  "mime_type": ""
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables")
  .setHeader("content-type", "application/json")
  .setBody("{\n  \"name\": \"\",\n  \"title\": \"\",\n  \"table_id\": \"\",\n  \"description\": \"\",\n  \"timestamp\": \"\",\n  \"tags\": [],\n  \"mime_type\": \"\"\n}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables"))
    .header("content-type", "application/json")
    .method("POST", HttpRequest.BodyPublishers.ofString("{\n  \"name\": \"\",\n  \"title\": \"\",\n  \"table_id\": \"\",\n  \"description\": \"\",\n  \"timestamp\": \"\",\n  \"tags\": [],\n  \"mime_type\": \"\"\n}"))
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n  \"name\": \"\",\n  \"title\": \"\",\n  \"table_id\": \"\",\n  \"description\": \"\",\n  \"timestamp\": \"\",\n  \"tags\": [],\n  \"mime_type\": \"\"\n}");
Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables")
  .post(body)
  .addHeader("content-type", "application/json")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables")
  .header("content-type", "application/json")
  .body("{\n  \"name\": \"\",\n  \"title\": \"\",\n  \"table_id\": \"\",\n  \"description\": \"\",\n  \"timestamp\": \"\",\n  \"tags\": [],\n  \"mime_type\": \"\"\n}")
  .asString();
const data = JSON.stringify({
  name: '',
  title: '',
  table_id: '',
  description: '',
  timestamp: '',
  tags: [],
  mime_type: ''
});

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('POST', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables');
xhr.setRequestHeader('content-type', 'application/json');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables',
  headers: {'content-type': 'application/json'},
  data: {
    name: '',
    title: '',
    table_id: '',
    description: '',
    timestamp: '',
    tags: [],
    mime_type: ''
  }
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"name":"","title":"","table_id":"","description":"","timestamp":"","tags":[],"mime_type":""}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables',
  method: 'POST',
  headers: {
    'content-type': 'application/json'
  },
  processData: false,
  data: '{\n  "name": "",\n  "title": "",\n  "table_id": "",\n  "description": "",\n  "timestamp": "",\n  "tags": [],\n  "mime_type": ""\n}'
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n  \"name\": \"\",\n  \"title\": \"\",\n  \"table_id\": \"\",\n  \"description\": \"\",\n  \"timestamp\": \"\",\n  \"tags\": [],\n  \"mime_type\": \"\"\n}")
val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables")
  .post(body)
  .addHeader("content-type", "application/json")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'POST',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables',
  headers: {
    'content-type': 'application/json'
  }
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.write(JSON.stringify({
  name: '',
  title: '',
  table_id: '',
  description: '',
  timestamp: '',
  tags: [],
  mime_type: ''
}));
req.end();
const request = require('request');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables',
  headers: {'content-type': 'application/json'},
  body: {
    name: '',
    title: '',
    table_id: '',
    description: '',
    timestamp: '',
    tags: [],
    mime_type: ''
  },
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('POST', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables');

req.headers({
  'content-type': 'application/json'
});

req.type('json');
req.send({
  name: '',
  title: '',
  table_id: '',
  description: '',
  timestamp: '',
  tags: [],
  mime_type: ''
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables',
  headers: {'content-type': 'application/json'},
  data: {
    name: '',
    title: '',
    table_id: '',
    description: '',
    timestamp: '',
    tags: [],
    mime_type: ''
  }
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"name":"","title":"","table_id":"","description":"","timestamp":"","tags":[],"mime_type":""}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"name": @"",
                              @"title": @"",
                              @"table_id": @"",
                              @"description": @"",
                              @"timestamp": @"",
                              @"tags": @[  ],
                              @"mime_type": @"" };

NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n  \"name\": \"\",\n  \"title\": \"\",\n  \"table_id\": \"\",\n  \"description\": \"\",\n  \"timestamp\": \"\",\n  \"tags\": [],\n  \"mime_type\": \"\"\n}" in

Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => json_encode([
    'name' => '',
    'title' => '',
    'table_id' => '',
    'description' => '',
    'timestamp' => '',
    'tags' => [
        
    ],
    'mime_type' => ''
  ]),
  CURLOPT_HTTPHEADER => [
    "content-type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('POST', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables', [
  'body' => '{
  "name": "",
  "title": "",
  "table_id": "",
  "description": "",
  "timestamp": "",
  "tags": [],
  "mime_type": ""
}',
  'headers' => [
    'content-type' => 'application/json',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$request->setContentType('application/json');
$request->setBody(json_encode([
  'name' => '',
  'title' => '',
  'table_id' => '',
  'description' => '',
  'timestamp' => '',
  'tags' => [
    
  ],
  'mime_type' => ''
]));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
append(json_encode([
  'name' => '',
  'title' => '',
  'table_id' => '',
  'description' => '',
  'timestamp' => '',
  'tags' => [
    
  ],
  'mime_type' => ''
]));
$request->setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables');
$request->setRequestMethod('POST');
$request->setBody($body);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "name": "",
  "title": "",
  "table_id": "",
  "description": "",
  "timestamp": "",
  "tags": [],
  "mime_type": ""
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "name": "",
  "title": "",
  "table_id": "",
  "description": "",
  "timestamp": "",
  "tags": [],
  "mime_type": ""
}'
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = "{\n  \"name\": \"\",\n  \"title\": \"\",\n  \"table_id\": \"\",\n  \"description\": \"\",\n  \"timestamp\": \"\",\n  \"tags\": [],\n  \"mime_type\": \"\"\n}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables"

payload = {
    "name": "",
    "title": "",
    "table_id": "",
    "description": "",
    "timestamp": "",
    "tags": [],
    "mime_type": ""
}
headers = {"content-type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables"

payload <- "{\n  \"name\": \"\",\n  \"title\": \"\",\n  \"table_id\": \"\",\n  \"description\": \"\",\n  \"timestamp\": \"\",\n  \"tags\": [],\n  \"mime_type\": \"\"\n}"

encode <- "json"

response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\n  \"name\": \"\",\n  \"title\": \"\",\n  \"table_id\": \"\",\n  \"description\": \"\",\n  \"timestamp\": \"\",\n  \"tags\": [],\n  \"mime_type\": \"\"\n}"

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/json'}
)

response = conn.post('/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables') do |req|
  req.body = "{\n  \"name\": \"\",\n  \"title\": \"\",\n  \"table_id\": \"\",\n  \"description\": \"\",\n  \"timestamp\": \"\",\n  \"tags\": [],\n  \"mime_type\": \"\"\n}"
end

puts response.status
puts response.body
use serde_json::json;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables";

    let payload = json!({
        "name": "",
        "title": "",
        "table_id": "",
        "description": "",
        "timestamp": "",
        "tags": (),
        "mime_type": ""
    });

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("content-type", "application/json".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.post(url)
        .headers(headers)
        .json(&payload)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request POST \
  --url {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables \
  --header 'content-type: application/json' \
  --data '{
  "name": "",
  "title": "",
  "table_id": "",
  "description": "",
  "timestamp": "",
  "tags": [],
  "mime_type": ""
}'
echo '{
  "name": "",
  "title": "",
  "table_id": "",
  "description": "",
  "timestamp": "",
  "tags": [],
  "mime_type": ""
}' |  \
  http POST {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables \
  content-type:application/json
wget --quiet \
  --method POST \
  --header 'content-type: application/json' \
  --body-data '{\n  "name": "",\n  "title": "",\n  "table_id": "",\n  "description": "",\n  "timestamp": "",\n  "tags": [],\n  "mime_type": ""\n}' \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables
import Foundation

let headers = ["content-type": "application/json"]
let parameters = [
  "name": "",
  "title": "",
  "table_id": "",
  "description": "",
  "timestamp": "",
  "tags": [],
  "mime_type": ""
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "name": "Roi data",
  "title": "ROI Data",
  "table_id": "1234f4567c",
  "description": "roi data for Q1",
  "mime_type": "text/csv",
  "timestamp": 1732810375150,
  "parent_id": "1234f4567c",
  "parents": [
    "1234f4567c"
  ]
}
POST Upsert rows
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows
QUERY PARAMS

wId
spaceId
dsId
tId
BODY json

{
  "rows": [
    {
      "row_id": "",
      "value": {}
    }
  ],
  "truncate": false
}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n  \"rows\": [\n    {\n      \"row_id\": \"\",\n      \"value\": {}\n    }\n  ],\n  \"truncate\": false\n}");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/post "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows" {:content-type :json
                                                                                                              :form-params {:rows [{:row_id ""
                                                                                                                                    :value {}}]
                                                                                                                            :truncate false}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows"
headers = HTTP::Headers{
  "content-type" => "application/json"
}
reqBody = "{\n  \"rows\": [\n    {\n      \"row_id\": \"\",\n      \"value\": {}\n    }\n  ],\n  \"truncate\": false\n}"

response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Post,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows"),
    Content = new StringContent("{\n  \"rows\": [\n    {\n      \"row_id\": \"\",\n      \"value\": {}\n    }\n  ],\n  \"truncate\": false\n}")
    {
        Headers =
        {
            ContentType = new MediaTypeHeaderValue("application/json")
        }
    }
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n  \"rows\": [\n    {\n      \"row_id\": \"\",\n      \"value\": {}\n    }\n  ],\n  \"truncate\": false\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows"

	payload := strings.NewReader("{\n  \"rows\": [\n    {\n      \"row_id\": \"\",\n      \"value\": {}\n    }\n  ],\n  \"truncate\": false\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("content-type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
POST /baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 90

{
  "rows": [
    {
      "row_id": "",
      "value": {}
    }
  ],
  "truncate": false
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows")
  .setHeader("content-type", "application/json")
  .setBody("{\n  \"rows\": [\n    {\n      \"row_id\": \"\",\n      \"value\": {}\n    }\n  ],\n  \"truncate\": false\n}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows"))
    .header("content-type", "application/json")
    .method("POST", HttpRequest.BodyPublishers.ofString("{\n  \"rows\": [\n    {\n      \"row_id\": \"\",\n      \"value\": {}\n    }\n  ],\n  \"truncate\": false\n}"))
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n  \"rows\": [\n    {\n      \"row_id\": \"\",\n      \"value\": {}\n    }\n  ],\n  \"truncate\": false\n}");
Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows")
  .post(body)
  .addHeader("content-type", "application/json")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows")
  .header("content-type", "application/json")
  .body("{\n  \"rows\": [\n    {\n      \"row_id\": \"\",\n      \"value\": {}\n    }\n  ],\n  \"truncate\": false\n}")
  .asString();
const data = JSON.stringify({
  rows: [
    {
      row_id: '',
      value: {}
    }
  ],
  truncate: false
});

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('POST', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows');
xhr.setRequestHeader('content-type', 'application/json');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows',
  headers: {'content-type': 'application/json'},
  data: {rows: [{row_id: '', value: {}}], truncate: false}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"rows":[{"row_id":"","value":{}}],"truncate":false}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows',
  method: 'POST',
  headers: {
    'content-type': 'application/json'
  },
  processData: false,
  data: '{\n  "rows": [\n    {\n      "row_id": "",\n      "value": {}\n    }\n  ],\n  "truncate": false\n}'
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n  \"rows\": [\n    {\n      \"row_id\": \"\",\n      \"value\": {}\n    }\n  ],\n  \"truncate\": false\n}")
val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows")
  .post(body)
  .addHeader("content-type", "application/json")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'POST',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows',
  headers: {
    'content-type': 'application/json'
  }
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.write(JSON.stringify({rows: [{row_id: '', value: {}}], truncate: false}));
req.end();
const request = require('request');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows',
  headers: {'content-type': 'application/json'},
  body: {rows: [{row_id: '', value: {}}], truncate: false},
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('POST', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows');

req.headers({
  'content-type': 'application/json'
});

req.type('json');
req.send({
  rows: [
    {
      row_id: '',
      value: {}
    }
  ],
  truncate: false
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows',
  headers: {'content-type': 'application/json'},
  data: {rows: [{row_id: '', value: {}}], truncate: false}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"rows":[{"row_id":"","value":{}}],"truncate":false}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"rows": @[ @{ @"row_id": @"", @"value": @{  } } ],
                              @"truncate": @NO };

NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n  \"rows\": [\n    {\n      \"row_id\": \"\",\n      \"value\": {}\n    }\n  ],\n  \"truncate\": false\n}" in

Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => json_encode([
    'rows' => [
        [
                'row_id' => '',
                'value' => [
                                
                ]
        ]
    ],
    'truncate' => null
  ]),
  CURLOPT_HTTPHEADER => [
    "content-type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('POST', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows', [
  'body' => '{
  "rows": [
    {
      "row_id": "",
      "value": {}
    }
  ],
  "truncate": false
}',
  'headers' => [
    'content-type' => 'application/json',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$request->setContentType('application/json');
$request->setBody(json_encode([
  'rows' => [
    [
        'row_id' => '',
        'value' => [
                
        ]
    ]
  ],
  'truncate' => null
]));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
append(json_encode([
  'rows' => [
    [
        'row_id' => '',
        'value' => [
                
        ]
    ]
  ],
  'truncate' => null
]));
$request->setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows');
$request->setRequestMethod('POST');
$request->setBody($body);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "rows": [
    {
      "row_id": "",
      "value": {}
    }
  ],
  "truncate": false
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "rows": [
    {
      "row_id": "",
      "value": {}
    }
  ],
  "truncate": false
}'
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = "{\n  \"rows\": [\n    {\n      \"row_id\": \"\",\n      \"value\": {}\n    }\n  ],\n  \"truncate\": false\n}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows"

payload = {
    "rows": [
        {
            "row_id": "",
            "value": {}
        }
    ],
    "truncate": False
}
headers = {"content-type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows"

payload <- "{\n  \"rows\": [\n    {\n      \"row_id\": \"\",\n      \"value\": {}\n    }\n  ],\n  \"truncate\": false\n}"

encode <- "json"

response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\n  \"rows\": [\n    {\n      \"row_id\": \"\",\n      \"value\": {}\n    }\n  ],\n  \"truncate\": false\n}"

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/json'}
)

response = conn.post('/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows') do |req|
  req.body = "{\n  \"rows\": [\n    {\n      \"row_id\": \"\",\n      \"value\": {}\n    }\n  ],\n  \"truncate\": false\n}"
end

puts response.status
puts response.body
use serde_json::json;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows";

    let payload = json!({
        "rows": (
            json!({
                "row_id": "",
                "value": json!({})
            })
        ),
        "truncate": false
    });

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("content-type", "application/json".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.post(url)
        .headers(headers)
        .json(&payload)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request POST \
  --url {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows \
  --header 'content-type: application/json' \
  --data '{
  "rows": [
    {
      "row_id": "",
      "value": {}
    }
  ],
  "truncate": false
}'
echo '{
  "rows": [
    {
      "row_id": "",
      "value": {}
    }
  ],
  "truncate": false
}' |  \
  http POST {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows \
  content-type:application/json
wget --quiet \
  --method POST \
  --header 'content-type: application/json' \
  --body-data '{\n  "rows": [\n    {\n      "row_id": "",\n      "value": {}\n    }\n  ],\n  "truncate": false\n}' \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows
import Foundation

let headers = ["content-type": "application/json"]
let parameters = [
  "rows": [
    [
      "row_id": "",
      "value": []
    ]
  ],
  "truncate": false
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_sources/:dsId/tables/:tId/rows")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "id": 12345,
  "createdAt": 1625097600,
  "name": "Customer Knowledge Base",
  "description": "Contains all customer-related information and FAQs",
  "dustAPIProjectId": "5e9d8c7b6a",
  "connectorId": "1f3e5d7c9b",
  "connectorProvider": "webcrawler",
  "assistantDefaultSelected": true
}
DELETE Delete a data source view
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId
QUERY PARAMS

wId
spaceId
dsvId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "DELETE");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/delete "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId"

response = HTTP::Client.delete url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Delete,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId");
var request = new RestRequest("", Method.Delete);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId"

	req, _ := http.NewRequest("DELETE", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
DELETE /baseUrl/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("DELETE", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId"))
    .method("DELETE", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId")
  .delete(null)
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.delete("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('DELETE', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'DELETE',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId';
const options = {method: 'DELETE'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId',
  method: 'DELETE',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId")
  .delete(null)
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'DELETE',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'DELETE',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('DELETE', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'DELETE',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId';
const options = {method: 'DELETE'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"DELETE"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId" in

Client.call `DELETE uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "DELETE",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('DELETE', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId');
$request->setMethod(HTTP_METH_DELETE);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId');
$request->setRequestMethod('DELETE');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId' -Method DELETE 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId' -Method DELETE 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("DELETE", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId"

response = requests.delete(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId"

response <- VERB("DELETE", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.delete('/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId') do |req|
end

puts response.status
puts response.body
use std::str::FromStr;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId";

    let client = reqwest::Client::new();
    let response = client.request(reqwest::Method::from_str("DELETE").unwrap(), url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request DELETE \
  --url {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId
http DELETE {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId
wget --quiet \
  --method DELETE \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "DELETE"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
GET Get a data source view
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId
QUERY PARAMS

wId
spaceId
dsvId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId"

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId"))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId');
$request->setMethod(HTTP_METH_GET);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId"

response = requests.get(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId"

response <- VERB("GET", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId') do |req|
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId";

    let client = reqwest::Client::new();
    let response = client.get(url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId
http GET {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId
wget --quiet \
  --method GET \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "dataSource": {
    "id": 12345,
    "createdAt": 1625097600,
    "name": "Customer Knowledge Base",
    "description": "Contains all customer-related information and FAQs",
    "dustAPIProjectId": "5e9d8c7b6a",
    "connectorId": "1f3e5d7c9b",
    "connectorProvider": "webcrawler",
    "assistantDefaultSelected": true
  }
}
GET List Data Source Views
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views
QUERY PARAMS

wId
spaceId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views"

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/spaces/:spaceId/data_source_views HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views"))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_source_views',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views');
$request->setMethod(HTTP_METH_GET);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_source_views")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views"

response = requests.get(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views"

response <- VERB("GET", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_source_views') do |req|
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views";

    let client = reqwest::Client::new();
    let response = client.get(url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views
http GET {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views
wget --quiet \
  --method GET \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
GET Search the data source view
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search
QUERY PARAMS

query
top_k
full_text
wId
spaceId
dsvId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text=");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search" {:query-params {:query ""
                                                                                                                        :top_k ""
                                                                                                                        :full_text ""}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text="

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text="),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text=");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text="

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text= HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text=")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text="))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text=")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text=")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text=');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search',
  params: {query: '', top_k: '', full_text: ''}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text=';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text=',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text=")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text=',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search',
  qs: {query: '', top_k: '', full_text: ''}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search');

req.query({
  query: '',
  top_k: '',
  full_text: ''
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search',
  params: {query: '', top_k: '', full_text: ''}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text=';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text="]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text=" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text=",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text=');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search');
$request->setMethod(HTTP_METH_GET);

$request->setQueryData([
  'query' => '',
  'top_k' => '',
  'full_text' => ''
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search');
$request->setRequestMethod('GET');
$request->setQuery(new http\QueryString([
  'query' => '',
  'top_k' => '',
  'full_text' => ''
]));

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text=' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text=' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text=")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search"

querystring = {"query":"","top_k":"","full_text":""}

response = requests.get(url, params=querystring)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search"

queryString <- list(
  query = "",
  top_k = "",
  full_text = ""
)

response <- VERB("GET", url, query = queryString, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text=")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search') do |req|
  req.params['query'] = ''
  req.params['top_k'] = ''
  req.params['full_text'] = ''
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search";

    let querystring = [
        ("query", ""),
        ("top_k", ""),
        ("full_text", ""),
    ];

    let client = reqwest::Client::new();
    let response = client.get(url)
        .query(&querystring)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text='
http GET '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text='
wget --quiet \
  --method GET \
  --output-document \
  - '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text='
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId/search?query=&top_k=&full_text=")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
PATCH Update a data source view
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId
QUERY PARAMS

wId
spaceId
dsvId
BODY json

{}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "PATCH");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{}");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/patch "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId" {:content-type :json})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId"
headers = HTTP::Headers{
  "content-type" => "application/json"
}
reqBody = "{}"

response = HTTP::Client.patch url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Patch,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId"),
    Content = new StringContent("{}")
    {
        Headers =
        {
            ContentType = new MediaTypeHeaderValue("application/json")
        }
    }
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId");
var request = new RestRequest("", Method.Patch);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{}", ParameterType.RequestBody);
var response = client.Execute(request);
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId"

	payload := strings.NewReader("{}")

	req, _ := http.NewRequest("PATCH", url, payload)

	req.Header.Add("content-type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
PATCH /baseUrl/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 2

{}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("PATCH", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId")
  .setHeader("content-type", "application/json")
  .setBody("{}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId"))
    .header("content-type", "application/json")
    .method("PATCH", HttpRequest.BodyPublishers.ofString("{}"))
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{}");
Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId")
  .patch(body)
  .addHeader("content-type", "application/json")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.patch("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId")
  .header("content-type", "application/json")
  .body("{}")
  .asString();
const data = JSON.stringify({});

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('PATCH', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId');
xhr.setRequestHeader('content-type', 'application/json');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'PATCH',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId',
  headers: {'content-type': 'application/json'},
  data: {}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId';
const options = {method: 'PATCH', headers: {'content-type': 'application/json'}, body: '{}'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId',
  method: 'PATCH',
  headers: {
    'content-type': 'application/json'
  },
  processData: false,
  data: '{}'
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{}")
val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId")
  .patch(body)
  .addHeader("content-type", "application/json")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'PATCH',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId',
  headers: {
    'content-type': 'application/json'
  }
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.write(JSON.stringify({}));
req.end();
const request = require('request');

const options = {
  method: 'PATCH',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId',
  headers: {'content-type': 'application/json'},
  body: {},
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('PATCH', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId');

req.headers({
  'content-type': 'application/json'
});

req.type('json');
req.send({});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'PATCH',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId',
  headers: {'content-type': 'application/json'},
  data: {}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId';
const options = {method: 'PATCH', headers: {'content-type': 'application/json'}, body: '{}'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{  };

NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"PATCH"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{}" in

Client.call ~headers ~body `PATCH uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "PATCH",
  CURLOPT_POSTFIELDS => json_encode([
    
  ]),
  CURLOPT_HTTPHEADER => [
    "content-type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('PATCH', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId', [
  'body' => '{}',
  'headers' => [
    'content-type' => 'application/json',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId');
$request->setMethod(HttpRequest::HTTP_METH_PATCH);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$request->setContentType('application/json');
$request->setBody(json_encode([
  
]));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
append(json_encode([
  
]));
$request->setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId');
$request->setRequestMethod('PATCH');
$request->setBody($body);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId' -Method PATCH -Headers $headers -ContentType 'application/json' -Body '{}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId' -Method PATCH -Headers $headers -ContentType 'application/json' -Body '{}'
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = "{}"

headers = { 'content-type': "application/json" }

conn.request("PATCH", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId"

payload = {}
headers = {"content-type": "application/json"}

response = requests.patch(url, json=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId"

payload <- "{}"

encode <- "json"

response <- VERB("PATCH", url, body = payload, content_type("application/json"), encode = encode)

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Patch.new(url)
request["content-type"] = 'application/json'
request.body = "{}"

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/json'}
)

response = conn.patch('/baseUrl/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId') do |req|
  req.body = "{}"
end

puts response.status
puts response.body
use std::str::FromStr;
use serde_json::json;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId";

    let payload = json!({});

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("content-type", "application/json".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.request(reqwest::Method::from_str("PATCH").unwrap(), url)
        .headers(headers)
        .json(&payload)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request PATCH \
  --url {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId \
  --header 'content-type: application/json' \
  --data '{}'
echo '{}' |  \
  http PATCH {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId \
  content-type:application/json
wget --quiet \
  --method PATCH \
  --header 'content-type: application/json' \
  --body-data '{}' \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId
import Foundation

let headers = ["content-type": "application/json"]
let parameters = [] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/data_source_views/:dsvId")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "PATCH"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
RESPONSE HEADERS

Content-Type
application/json
RESPONSE BODY json

{
  "dataSource": {
    "id": 12345,
    "createdAt": 1625097600,
    "name": "Customer Knowledge Base",
    "description": "Contains all customer-related information and FAQs",
    "dustAPIProjectId": "5e9d8c7b6a",
    "connectorId": "1f3e5d7c9b",
    "connectorProvider": "webcrawler",
    "assistantDefaultSelected": true
  }
}
DELETE Delete feedback for a specific message
{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks
QUERY PARAMS

wId
cId
mId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "DELETE");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/delete "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks"

response = HTTP::Client.delete url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Delete,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks");
var request = new RestRequest("", Method.Delete);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks"

	req, _ := http.NewRequest("DELETE", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
DELETE /baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("DELETE", "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks"))
    .method("DELETE", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks")
  .delete(null)
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.delete("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('DELETE', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'DELETE',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks';
const options = {method: 'DELETE'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks',
  method: 'DELETE',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks")
  .delete(null)
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'DELETE',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'DELETE',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('DELETE', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'DELETE',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks';
const options = {method: 'DELETE'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"DELETE"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks" in

Client.call `DELETE uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "DELETE",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('DELETE', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks');
$request->setMethod(HTTP_METH_DELETE);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks');
$request->setRequestMethod('DELETE');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks' -Method DELETE 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks' -Method DELETE 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("DELETE", "/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks"

response = requests.delete(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks"

response <- VERB("DELETE", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Delete.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.delete('/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks') do |req|
end

puts response.status
puts response.body
use std::str::FromStr;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks";

    let client = reqwest::Client::new();
    let response = client.request(reqwest::Method::from_str("DELETE").unwrap(), url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request DELETE \
  --url {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks
http DELETE {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks
wget --quiet \
  --method DELETE \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "DELETE"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
GET Get feedbacks for a conversation
{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks
QUERY PARAMS

wId
cId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks"

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/assistant/conversations/:cId/feedbacks HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks"))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/feedbacks',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks');
$request->setMethod(HTTP_METH_GET);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/feedbacks")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks"

response = requests.get(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks"

response <- VERB("GET", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/feedbacks') do |req|
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks";

    let client = reqwest::Client::new();
    let response = client.get(url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks
http GET {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks
wget --quiet \
  --method GET \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/feedbacks")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
POST Submit feedback for a specific message in a conversation
{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks
QUERY PARAMS

wId
cId
mId
BODY json

{
  "thumbDirection": "",
  "feedbackContent": "",
  "isConversationShared": false
}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n  \"thumbDirection\": \"\",\n  \"feedbackContent\": \"\",\n  \"isConversationShared\": false\n}");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/post "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks" {:content-type :json
                                                                                                               :form-params {:thumbDirection ""
                                                                                                                             :feedbackContent ""
                                                                                                                             :isConversationShared false}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks"
headers = HTTP::Headers{
  "content-type" => "application/json"
}
reqBody = "{\n  \"thumbDirection\": \"\",\n  \"feedbackContent\": \"\",\n  \"isConversationShared\": false\n}"

response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Post,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks"),
    Content = new StringContent("{\n  \"thumbDirection\": \"\",\n  \"feedbackContent\": \"\",\n  \"isConversationShared\": false\n}")
    {
        Headers =
        {
            ContentType = new MediaTypeHeaderValue("application/json")
        }
    }
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n  \"thumbDirection\": \"\",\n  \"feedbackContent\": \"\",\n  \"isConversationShared\": false\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks"

	payload := strings.NewReader("{\n  \"thumbDirection\": \"\",\n  \"feedbackContent\": \"\",\n  \"isConversationShared\": false\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("content-type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
POST /baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 84

{
  "thumbDirection": "",
  "feedbackContent": "",
  "isConversationShared": false
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks")
  .setHeader("content-type", "application/json")
  .setBody("{\n  \"thumbDirection\": \"\",\n  \"feedbackContent\": \"\",\n  \"isConversationShared\": false\n}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks"))
    .header("content-type", "application/json")
    .method("POST", HttpRequest.BodyPublishers.ofString("{\n  \"thumbDirection\": \"\",\n  \"feedbackContent\": \"\",\n  \"isConversationShared\": false\n}"))
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n  \"thumbDirection\": \"\",\n  \"feedbackContent\": \"\",\n  \"isConversationShared\": false\n}");
Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks")
  .post(body)
  .addHeader("content-type", "application/json")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks")
  .header("content-type", "application/json")
  .body("{\n  \"thumbDirection\": \"\",\n  \"feedbackContent\": \"\",\n  \"isConversationShared\": false\n}")
  .asString();
const data = JSON.stringify({
  thumbDirection: '',
  feedbackContent: '',
  isConversationShared: false
});

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('POST', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks');
xhr.setRequestHeader('content-type', 'application/json');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks',
  headers: {'content-type': 'application/json'},
  data: {thumbDirection: '', feedbackContent: '', isConversationShared: false}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"thumbDirection":"","feedbackContent":"","isConversationShared":false}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks',
  method: 'POST',
  headers: {
    'content-type': 'application/json'
  },
  processData: false,
  data: '{\n  "thumbDirection": "",\n  "feedbackContent": "",\n  "isConversationShared": false\n}'
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n  \"thumbDirection\": \"\",\n  \"feedbackContent\": \"\",\n  \"isConversationShared\": false\n}")
val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks")
  .post(body)
  .addHeader("content-type", "application/json")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'POST',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks',
  headers: {
    'content-type': 'application/json'
  }
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.write(JSON.stringify({thumbDirection: '', feedbackContent: '', isConversationShared: false}));
req.end();
const request = require('request');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks',
  headers: {'content-type': 'application/json'},
  body: {thumbDirection: '', feedbackContent: '', isConversationShared: false},
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('POST', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks');

req.headers({
  'content-type': 'application/json'
});

req.type('json');
req.send({
  thumbDirection: '',
  feedbackContent: '',
  isConversationShared: false
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks',
  headers: {'content-type': 'application/json'},
  data: {thumbDirection: '', feedbackContent: '', isConversationShared: false}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"thumbDirection":"","feedbackContent":"","isConversationShared":false}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"thumbDirection": @"",
                              @"feedbackContent": @"",
                              @"isConversationShared": @NO };

NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n  \"thumbDirection\": \"\",\n  \"feedbackContent\": \"\",\n  \"isConversationShared\": false\n}" in

Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => json_encode([
    'thumbDirection' => '',
    'feedbackContent' => '',
    'isConversationShared' => null
  ]),
  CURLOPT_HTTPHEADER => [
    "content-type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('POST', '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks', [
  'body' => '{
  "thumbDirection": "",
  "feedbackContent": "",
  "isConversationShared": false
}',
  'headers' => [
    'content-type' => 'application/json',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$request->setContentType('application/json');
$request->setBody(json_encode([
  'thumbDirection' => '',
  'feedbackContent' => '',
  'isConversationShared' => null
]));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
append(json_encode([
  'thumbDirection' => '',
  'feedbackContent' => '',
  'isConversationShared' => null
]));
$request->setRequestUrl('{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks');
$request->setRequestMethod('POST');
$request->setBody($body);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "thumbDirection": "",
  "feedbackContent": "",
  "isConversationShared": false
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "thumbDirection": "",
  "feedbackContent": "",
  "isConversationShared": false
}'
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = "{\n  \"thumbDirection\": \"\",\n  \"feedbackContent\": \"\",\n  \"isConversationShared\": false\n}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks"

payload = {
    "thumbDirection": "",
    "feedbackContent": "",
    "isConversationShared": False
}
headers = {"content-type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks"

payload <- "{\n  \"thumbDirection\": \"\",\n  \"feedbackContent\": \"\",\n  \"isConversationShared\": false\n}"

encode <- "json"

response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\n  \"thumbDirection\": \"\",\n  \"feedbackContent\": \"\",\n  \"isConversationShared\": false\n}"

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/json'}
)

response = conn.post('/baseUrl/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks') do |req|
  req.body = "{\n  \"thumbDirection\": \"\",\n  \"feedbackContent\": \"\",\n  \"isConversationShared\": false\n}"
end

puts response.status
puts response.body
use serde_json::json;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks";

    let payload = json!({
        "thumbDirection": "",
        "feedbackContent": "",
        "isConversationShared": false
    });

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("content-type", "application/json".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.post(url)
        .headers(headers)
        .json(&payload)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request POST \
  --url {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks \
  --header 'content-type: application/json' \
  --data '{
  "thumbDirection": "",
  "feedbackContent": "",
  "isConversationShared": false
}'
echo '{
  "thumbDirection": "",
  "feedbackContent": "",
  "isConversationShared": false
}' |  \
  http POST {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks \
  content-type:application/json
wget --quiet \
  --method POST \
  --header 'content-type: application/json' \
  --body-data '{\n  "thumbDirection": "",\n  "feedbackContent": "",\n  "isConversationShared": false\n}' \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks
import Foundation

let headers = ["content-type": "application/json"]
let parameters = [
  "thumbDirection": "",
  "feedbackContent": "",
  "isConversationShared": false
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/assistant/conversations/:cId/messages/:mId/feedbacks")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
POST Register a client-side MCP server
{{baseUrl}}/api/v1/w/:wId/mcp/register
QUERY PARAMS

wId
BODY json

{
  "serverName": ""
}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/mcp/register");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n  \"serverName\": \"\"\n}");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/post "{{baseUrl}}/api/v1/w/:wId/mcp/register" {:content-type :json
                                                                       :form-params {:serverName ""}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/mcp/register"
headers = HTTP::Headers{
  "content-type" => "application/json"
}
reqBody = "{\n  \"serverName\": \"\"\n}"

response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Post,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/mcp/register"),
    Content = new StringContent("{\n  \"serverName\": \"\"\n}")
    {
        Headers =
        {
            ContentType = new MediaTypeHeaderValue("application/json")
        }
    }
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/mcp/register");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n  \"serverName\": \"\"\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/mcp/register"

	payload := strings.NewReader("{\n  \"serverName\": \"\"\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("content-type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
POST /baseUrl/api/v1/w/:wId/mcp/register HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 22

{
  "serverName": ""
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/api/v1/w/:wId/mcp/register")
  .setHeader("content-type", "application/json")
  .setBody("{\n  \"serverName\": \"\"\n}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/mcp/register"))
    .header("content-type", "application/json")
    .method("POST", HttpRequest.BodyPublishers.ofString("{\n  \"serverName\": \"\"\n}"))
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n  \"serverName\": \"\"\n}");
Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/mcp/register")
  .post(body)
  .addHeader("content-type", "application/json")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/api/v1/w/:wId/mcp/register")
  .header("content-type", "application/json")
  .body("{\n  \"serverName\": \"\"\n}")
  .asString();
const data = JSON.stringify({
  serverName: ''
});

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('POST', '{{baseUrl}}/api/v1/w/:wId/mcp/register');
xhr.setRequestHeader('content-type', 'application/json');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/mcp/register',
  headers: {'content-type': 'application/json'},
  data: {serverName: ''}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/mcp/register';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"serverName":""}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/mcp/register',
  method: 'POST',
  headers: {
    'content-type': 'application/json'
  },
  processData: false,
  data: '{\n  "serverName": ""\n}'
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n  \"serverName\": \"\"\n}")
val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/mcp/register")
  .post(body)
  .addHeader("content-type", "application/json")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'POST',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/mcp/register',
  headers: {
    'content-type': 'application/json'
  }
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.write(JSON.stringify({serverName: ''}));
req.end();
const request = require('request');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/mcp/register',
  headers: {'content-type': 'application/json'},
  body: {serverName: ''},
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('POST', '{{baseUrl}}/api/v1/w/:wId/mcp/register');

req.headers({
  'content-type': 'application/json'
});

req.type('json');
req.send({
  serverName: ''
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/mcp/register',
  headers: {'content-type': 'application/json'},
  data: {serverName: ''}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/mcp/register';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"serverName":""}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"serverName": @"" };

NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/mcp/register"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/mcp/register" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n  \"serverName\": \"\"\n}" in

Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/mcp/register",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => json_encode([
    'serverName' => ''
  ]),
  CURLOPT_HTTPHEADER => [
    "content-type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('POST', '{{baseUrl}}/api/v1/w/:wId/mcp/register', [
  'body' => '{
  "serverName": ""
}',
  'headers' => [
    'content-type' => 'application/json',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/mcp/register');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$request->setContentType('application/json');
$request->setBody(json_encode([
  'serverName' => ''
]));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
append(json_encode([
  'serverName' => ''
]));
$request->setRequestUrl('{{baseUrl}}/api/v1/w/:wId/mcp/register');
$request->setRequestMethod('POST');
$request->setBody($body);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/mcp/register' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "serverName": ""
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/mcp/register' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "serverName": ""
}'
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = "{\n  \"serverName\": \"\"\n}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/baseUrl/api/v1/w/:wId/mcp/register", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/mcp/register"

payload = { "serverName": "" }
headers = {"content-type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/mcp/register"

payload <- "{\n  \"serverName\": \"\"\n}"

encode <- "json"

response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/mcp/register")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\n  \"serverName\": \"\"\n}"

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/json'}
)

response = conn.post('/baseUrl/api/v1/w/:wId/mcp/register') do |req|
  req.body = "{\n  \"serverName\": \"\"\n}"
end

puts response.status
puts response.body
use serde_json::json;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/mcp/register";

    let payload = json!({"serverName": ""});

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("content-type", "application/json".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.post(url)
        .headers(headers)
        .json(&payload)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request POST \
  --url {{baseUrl}}/api/v1/w/:wId/mcp/register \
  --header 'content-type: application/json' \
  --data '{
  "serverName": ""
}'
echo '{
  "serverName": ""
}' |  \
  http POST {{baseUrl}}/api/v1/w/:wId/mcp/register \
  content-type:application/json
wget --quiet \
  --method POST \
  --header 'content-type: application/json' \
  --body-data '{\n  "serverName": ""\n}' \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/mcp/register
import Foundation

let headers = ["content-type": "application/json"]
let parameters = ["serverName": ""] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/mcp/register")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
GET Stream MCP tool requests for a workspace
{{baseUrl}}/api/v1/w/:wId/mcp/requests
QUERY PARAMS

serverId
wId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId=");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/mcp/requests" {:query-params {:serverId ""}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId="

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId="),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId=");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId="

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/mcp/requests?serverId= HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId=")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId="))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId=")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId=")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId=');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/mcp/requests',
  params: {serverId: ''}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId=';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId=',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId=")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/mcp/requests?serverId=',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/mcp/requests',
  qs: {serverId: ''}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/mcp/requests');

req.query({
  serverId: ''
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/mcp/requests',
  params: {serverId: ''}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId=';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId="]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId=" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId=",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId=');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/mcp/requests');
$request->setMethod(HTTP_METH_GET);

$request->setQueryData([
  'serverId' => ''
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/mcp/requests');
$request->setRequestMethod('GET');
$request->setQuery(new http\QueryString([
  'serverId' => ''
]));

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId=' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId=' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/mcp/requests?serverId=")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/mcp/requests"

querystring = {"serverId":""}

response = requests.get(url, params=querystring)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/mcp/requests"

queryString <- list(serverId = "")

response <- VERB("GET", url, query = queryString, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId=")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/mcp/requests') do |req|
  req.params['serverId'] = ''
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/mcp/requests";

    let querystring = [
        ("serverId", ""),
    ];

    let client = reqwest::Client::new();
    let response = client.get(url)
        .query(&querystring)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url '{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId='
http GET '{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId='
wget --quiet \
  --method GET \
  --output-document \
  - '{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId='
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/mcp/requests?serverId=")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
POST Submit MCP tool execution results
{{baseUrl}}/api/v1/w/:wId/mcp/results
QUERY PARAMS

wId
BODY json

{
  "result": {},
  "serverId": ""
}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/mcp/results");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n  \"result\": {},\n  \"serverId\": \"\"\n}");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/post "{{baseUrl}}/api/v1/w/:wId/mcp/results" {:content-type :json
                                                                      :form-params {:result {}
                                                                                    :serverId ""}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/mcp/results"
headers = HTTP::Headers{
  "content-type" => "application/json"
}
reqBody = "{\n  \"result\": {},\n  \"serverId\": \"\"\n}"

response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Post,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/mcp/results"),
    Content = new StringContent("{\n  \"result\": {},\n  \"serverId\": \"\"\n}")
    {
        Headers =
        {
            ContentType = new MediaTypeHeaderValue("application/json")
        }
    }
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/mcp/results");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n  \"result\": {},\n  \"serverId\": \"\"\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/mcp/results"

	payload := strings.NewReader("{\n  \"result\": {},\n  \"serverId\": \"\"\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("content-type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
POST /baseUrl/api/v1/w/:wId/mcp/results HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 36

{
  "result": {},
  "serverId": ""
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/api/v1/w/:wId/mcp/results")
  .setHeader("content-type", "application/json")
  .setBody("{\n  \"result\": {},\n  \"serverId\": \"\"\n}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/mcp/results"))
    .header("content-type", "application/json")
    .method("POST", HttpRequest.BodyPublishers.ofString("{\n  \"result\": {},\n  \"serverId\": \"\"\n}"))
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n  \"result\": {},\n  \"serverId\": \"\"\n}");
Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/mcp/results")
  .post(body)
  .addHeader("content-type", "application/json")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/api/v1/w/:wId/mcp/results")
  .header("content-type", "application/json")
  .body("{\n  \"result\": {},\n  \"serverId\": \"\"\n}")
  .asString();
const data = JSON.stringify({
  result: {},
  serverId: ''
});

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('POST', '{{baseUrl}}/api/v1/w/:wId/mcp/results');
xhr.setRequestHeader('content-type', 'application/json');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/mcp/results',
  headers: {'content-type': 'application/json'},
  data: {result: {}, serverId: ''}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/mcp/results';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"result":{},"serverId":""}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/mcp/results',
  method: 'POST',
  headers: {
    'content-type': 'application/json'
  },
  processData: false,
  data: '{\n  "result": {},\n  "serverId": ""\n}'
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n  \"result\": {},\n  \"serverId\": \"\"\n}")
val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/mcp/results")
  .post(body)
  .addHeader("content-type", "application/json")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'POST',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/mcp/results',
  headers: {
    'content-type': 'application/json'
  }
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.write(JSON.stringify({result: {}, serverId: ''}));
req.end();
const request = require('request');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/mcp/results',
  headers: {'content-type': 'application/json'},
  body: {result: {}, serverId: ''},
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('POST', '{{baseUrl}}/api/v1/w/:wId/mcp/results');

req.headers({
  'content-type': 'application/json'
});

req.type('json');
req.send({
  result: {},
  serverId: ''
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/mcp/results',
  headers: {'content-type': 'application/json'},
  data: {result: {}, serverId: ''}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/mcp/results';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"result":{},"serverId":""}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"result": @{  },
                              @"serverId": @"" };

NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/mcp/results"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/mcp/results" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n  \"result\": {},\n  \"serverId\": \"\"\n}" in

Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/mcp/results",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => json_encode([
    'result' => [
        
    ],
    'serverId' => ''
  ]),
  CURLOPT_HTTPHEADER => [
    "content-type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('POST', '{{baseUrl}}/api/v1/w/:wId/mcp/results', [
  'body' => '{
  "result": {},
  "serverId": ""
}',
  'headers' => [
    'content-type' => 'application/json',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/mcp/results');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$request->setContentType('application/json');
$request->setBody(json_encode([
  'result' => [
    
  ],
  'serverId' => ''
]));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
append(json_encode([
  'result' => [
    
  ],
  'serverId' => ''
]));
$request->setRequestUrl('{{baseUrl}}/api/v1/w/:wId/mcp/results');
$request->setRequestMethod('POST');
$request->setBody($body);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/mcp/results' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "result": {},
  "serverId": ""
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/mcp/results' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "result": {},
  "serverId": ""
}'
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = "{\n  \"result\": {},\n  \"serverId\": \"\"\n}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/baseUrl/api/v1/w/:wId/mcp/results", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/mcp/results"

payload = {
    "result": {},
    "serverId": ""
}
headers = {"content-type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/mcp/results"

payload <- "{\n  \"result\": {},\n  \"serverId\": \"\"\n}"

encode <- "json"

response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/mcp/results")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\n  \"result\": {},\n  \"serverId\": \"\"\n}"

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/json'}
)

response = conn.post('/baseUrl/api/v1/w/:wId/mcp/results') do |req|
  req.body = "{\n  \"result\": {},\n  \"serverId\": \"\"\n}"
end

puts response.status
puts response.body
use serde_json::json;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/mcp/results";

    let payload = json!({
        "result": json!({}),
        "serverId": ""
    });

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("content-type", "application/json".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.post(url)
        .headers(headers)
        .json(&payload)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request POST \
  --url {{baseUrl}}/api/v1/w/:wId/mcp/results \
  --header 'content-type: application/json' \
  --data '{
  "result": {},
  "serverId": ""
}'
echo '{
  "result": {},
  "serverId": ""
}' |  \
  http POST {{baseUrl}}/api/v1/w/:wId/mcp/results \
  content-type:application/json
wget --quiet \
  --method POST \
  --header 'content-type: application/json' \
  --body-data '{\n  "result": {},\n  "serverId": ""\n}' \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/mcp/results
import Foundation

let headers = ["content-type": "application/json"]
let parameters = [
  "result": [],
  "serverId": ""
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/mcp/results")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
POST Update heartbeat for a client-side MCP server
{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat
QUERY PARAMS

wId
BODY json

{
  "serverId": ""
}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n  \"serverId\": \"\"\n}");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/post "{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat" {:content-type :json
                                                                        :form-params {:serverId ""}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat"
headers = HTTP::Headers{
  "content-type" => "application/json"
}
reqBody = "{\n  \"serverId\": \"\"\n}"

response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Post,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat"),
    Content = new StringContent("{\n  \"serverId\": \"\"\n}")
    {
        Headers =
        {
            ContentType = new MediaTypeHeaderValue("application/json")
        }
    }
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n  \"serverId\": \"\"\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat"

	payload := strings.NewReader("{\n  \"serverId\": \"\"\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("content-type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
POST /baseUrl/api/v1/w/:wId/mcp/heartbeat HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 20

{
  "serverId": ""
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat")
  .setHeader("content-type", "application/json")
  .setBody("{\n  \"serverId\": \"\"\n}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat"))
    .header("content-type", "application/json")
    .method("POST", HttpRequest.BodyPublishers.ofString("{\n  \"serverId\": \"\"\n}"))
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n  \"serverId\": \"\"\n}");
Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat")
  .post(body)
  .addHeader("content-type", "application/json")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat")
  .header("content-type", "application/json")
  .body("{\n  \"serverId\": \"\"\n}")
  .asString();
const data = JSON.stringify({
  serverId: ''
});

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('POST', '{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat');
xhr.setRequestHeader('content-type', 'application/json');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat',
  headers: {'content-type': 'application/json'},
  data: {serverId: ''}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"serverId":""}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat',
  method: 'POST',
  headers: {
    'content-type': 'application/json'
  },
  processData: false,
  data: '{\n  "serverId": ""\n}'
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n  \"serverId\": \"\"\n}")
val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat")
  .post(body)
  .addHeader("content-type", "application/json")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'POST',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/mcp/heartbeat',
  headers: {
    'content-type': 'application/json'
  }
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.write(JSON.stringify({serverId: ''}));
req.end();
const request = require('request');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat',
  headers: {'content-type': 'application/json'},
  body: {serverId: ''},
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('POST', '{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat');

req.headers({
  'content-type': 'application/json'
});

req.type('json');
req.send({
  serverId: ''
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat',
  headers: {'content-type': 'application/json'},
  data: {serverId: ''}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"serverId":""}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"serverId": @"" };

NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n  \"serverId\": \"\"\n}" in

Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => json_encode([
    'serverId' => ''
  ]),
  CURLOPT_HTTPHEADER => [
    "content-type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('POST', '{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat', [
  'body' => '{
  "serverId": ""
}',
  'headers' => [
    'content-type' => 'application/json',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$request->setContentType('application/json');
$request->setBody(json_encode([
  'serverId' => ''
]));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
append(json_encode([
  'serverId' => ''
]));
$request->setRequestUrl('{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat');
$request->setRequestMethod('POST');
$request->setBody($body);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "serverId": ""
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "serverId": ""
}'
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = "{\n  \"serverId\": \"\"\n}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/baseUrl/api/v1/w/:wId/mcp/heartbeat", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat"

payload = { "serverId": "" }
headers = {"content-type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat"

payload <- "{\n  \"serverId\": \"\"\n}"

encode <- "json"

response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\n  \"serverId\": \"\"\n}"

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/json'}
)

response = conn.post('/baseUrl/api/v1/w/:wId/mcp/heartbeat') do |req|
  req.body = "{\n  \"serverId\": \"\"\n}"
end

puts response.status
puts response.body
use serde_json::json;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat";

    let payload = json!({"serverId": ""});

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("content-type", "application/json".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.post(url)
        .headers(headers)
        .json(&payload)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request POST \
  --url {{baseUrl}}/api/v1/w/:wId/mcp/heartbeat \
  --header 'content-type: application/json' \
  --data '{
  "serverId": ""
}'
echo '{
  "serverId": ""
}' |  \
  http POST {{baseUrl}}/api/v1/w/:wId/mcp/heartbeat \
  content-type:application/json
wget --quiet \
  --method POST \
  --header 'content-type: application/json' \
  --body-data '{\n  "serverId": ""\n}' \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/mcp/heartbeat
import Foundation

let headers = ["content-type": "application/json"]
let parameters = ["serverId": ""] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/mcp/heartbeat")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
POST Search for nodes in the workspace
{{baseUrl}}/api/v1/w/:wId/search
QUERY PARAMS

wId
BODY json

{
  "query": "",
  "includeDataSources": false,
  "viewType": "",
  "spaceIds": [],
  "nodeIds": [],
  "searchSourceUrls": false
}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/search");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{\n  \"query\": \"\",\n  \"includeDataSources\": false,\n  \"viewType\": \"\",\n  \"spaceIds\": [],\n  \"nodeIds\": [],\n  \"searchSourceUrls\": false\n}");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/post "{{baseUrl}}/api/v1/w/:wId/search" {:content-type :json
                                                                 :form-params {:query ""
                                                                               :includeDataSources false
                                                                               :viewType ""
                                                                               :spaceIds []
                                                                               :nodeIds []
                                                                               :searchSourceUrls false}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/search"
headers = HTTP::Headers{
  "content-type" => "application/json"
}
reqBody = "{\n  \"query\": \"\",\n  \"includeDataSources\": false,\n  \"viewType\": \"\",\n  \"spaceIds\": [],\n  \"nodeIds\": [],\n  \"searchSourceUrls\": false\n}"

response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Post,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/search"),
    Content = new StringContent("{\n  \"query\": \"\",\n  \"includeDataSources\": false,\n  \"viewType\": \"\",\n  \"spaceIds\": [],\n  \"nodeIds\": [],\n  \"searchSourceUrls\": false\n}")
    {
        Headers =
        {
            ContentType = new MediaTypeHeaderValue("application/json")
        }
    }
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/search");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{\n  \"query\": \"\",\n  \"includeDataSources\": false,\n  \"viewType\": \"\",\n  \"spaceIds\": [],\n  \"nodeIds\": [],\n  \"searchSourceUrls\": false\n}", ParameterType.RequestBody);
var response = client.Execute(request);
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/search"

	payload := strings.NewReader("{\n  \"query\": \"\",\n  \"includeDataSources\": false,\n  \"viewType\": \"\",\n  \"spaceIds\": [],\n  \"nodeIds\": [],\n  \"searchSourceUrls\": false\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("content-type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
POST /baseUrl/api/v1/w/:wId/search HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 130

{
  "query": "",
  "includeDataSources": false,
  "viewType": "",
  "spaceIds": [],
  "nodeIds": [],
  "searchSourceUrls": false
}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/api/v1/w/:wId/search")
  .setHeader("content-type", "application/json")
  .setBody("{\n  \"query\": \"\",\n  \"includeDataSources\": false,\n  \"viewType\": \"\",\n  \"spaceIds\": [],\n  \"nodeIds\": [],\n  \"searchSourceUrls\": false\n}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/search"))
    .header("content-type", "application/json")
    .method("POST", HttpRequest.BodyPublishers.ofString("{\n  \"query\": \"\",\n  \"includeDataSources\": false,\n  \"viewType\": \"\",\n  \"spaceIds\": [],\n  \"nodeIds\": [],\n  \"searchSourceUrls\": false\n}"))
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\n  \"query\": \"\",\n  \"includeDataSources\": false,\n  \"viewType\": \"\",\n  \"spaceIds\": [],\n  \"nodeIds\": [],\n  \"searchSourceUrls\": false\n}");
Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/search")
  .post(body)
  .addHeader("content-type", "application/json")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/api/v1/w/:wId/search")
  .header("content-type", "application/json")
  .body("{\n  \"query\": \"\",\n  \"includeDataSources\": false,\n  \"viewType\": \"\",\n  \"spaceIds\": [],\n  \"nodeIds\": [],\n  \"searchSourceUrls\": false\n}")
  .asString();
const data = JSON.stringify({
  query: '',
  includeDataSources: false,
  viewType: '',
  spaceIds: [],
  nodeIds: [],
  searchSourceUrls: false
});

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('POST', '{{baseUrl}}/api/v1/w/:wId/search');
xhr.setRequestHeader('content-type', 'application/json');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/search',
  headers: {'content-type': 'application/json'},
  data: {
    query: '',
    includeDataSources: false,
    viewType: '',
    spaceIds: [],
    nodeIds: [],
    searchSourceUrls: false
  }
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/search';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"query":"","includeDataSources":false,"viewType":"","spaceIds":[],"nodeIds":[],"searchSourceUrls":false}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/search',
  method: 'POST',
  headers: {
    'content-type': 'application/json'
  },
  processData: false,
  data: '{\n  "query": "",\n  "includeDataSources": false,\n  "viewType": "",\n  "spaceIds": [],\n  "nodeIds": [],\n  "searchSourceUrls": false\n}'
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{\n  \"query\": \"\",\n  \"includeDataSources\": false,\n  \"viewType\": \"\",\n  \"spaceIds\": [],\n  \"nodeIds\": [],\n  \"searchSourceUrls\": false\n}")
val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/search")
  .post(body)
  .addHeader("content-type", "application/json")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'POST',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/search',
  headers: {
    'content-type': 'application/json'
  }
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.write(JSON.stringify({
  query: '',
  includeDataSources: false,
  viewType: '',
  spaceIds: [],
  nodeIds: [],
  searchSourceUrls: false
}));
req.end();
const request = require('request');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/search',
  headers: {'content-type': 'application/json'},
  body: {
    query: '',
    includeDataSources: false,
    viewType: '',
    spaceIds: [],
    nodeIds: [],
    searchSourceUrls: false
  },
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('POST', '{{baseUrl}}/api/v1/w/:wId/search');

req.headers({
  'content-type': 'application/json'
});

req.type('json');
req.send({
  query: '',
  includeDataSources: false,
  viewType: '',
  spaceIds: [],
  nodeIds: [],
  searchSourceUrls: false
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/search',
  headers: {'content-type': 'application/json'},
  data: {
    query: '',
    includeDataSources: false,
    viewType: '',
    spaceIds: [],
    nodeIds: [],
    searchSourceUrls: false
  }
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/search';
const options = {
  method: 'POST',
  headers: {'content-type': 'application/json'},
  body: '{"query":"","includeDataSources":false,"viewType":"","spaceIds":[],"nodeIds":[],"searchSourceUrls":false}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{ @"query": @"",
                              @"includeDataSources": @NO,
                              @"viewType": @"",
                              @"spaceIds": @[  ],
                              @"nodeIds": @[  ],
                              @"searchSourceUrls": @NO };

NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/search"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/search" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{\n  \"query\": \"\",\n  \"includeDataSources\": false,\n  \"viewType\": \"\",\n  \"spaceIds\": [],\n  \"nodeIds\": [],\n  \"searchSourceUrls\": false\n}" in

Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/search",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => json_encode([
    'query' => '',
    'includeDataSources' => null,
    'viewType' => '',
    'spaceIds' => [
        
    ],
    'nodeIds' => [
        
    ],
    'searchSourceUrls' => null
  ]),
  CURLOPT_HTTPHEADER => [
    "content-type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('POST', '{{baseUrl}}/api/v1/w/:wId/search', [
  'body' => '{
  "query": "",
  "includeDataSources": false,
  "viewType": "",
  "spaceIds": [],
  "nodeIds": [],
  "searchSourceUrls": false
}',
  'headers' => [
    'content-type' => 'application/json',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/search');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$request->setContentType('application/json');
$request->setBody(json_encode([
  'query' => '',
  'includeDataSources' => null,
  'viewType' => '',
  'spaceIds' => [
    
  ],
  'nodeIds' => [
    
  ],
  'searchSourceUrls' => null
]));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
append(json_encode([
  'query' => '',
  'includeDataSources' => null,
  'viewType' => '',
  'spaceIds' => [
    
  ],
  'nodeIds' => [
    
  ],
  'searchSourceUrls' => null
]));
$request->setRequestUrl('{{baseUrl}}/api/v1/w/:wId/search');
$request->setRequestMethod('POST');
$request->setBody($body);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/search' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "query": "",
  "includeDataSources": false,
  "viewType": "",
  "spaceIds": [],
  "nodeIds": [],
  "searchSourceUrls": false
}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/search' -Method POST -Headers $headers -ContentType 'application/json' -Body '{
  "query": "",
  "includeDataSources": false,
  "viewType": "",
  "spaceIds": [],
  "nodeIds": [],
  "searchSourceUrls": false
}'
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = "{\n  \"query\": \"\",\n  \"includeDataSources\": false,\n  \"viewType\": \"\",\n  \"spaceIds\": [],\n  \"nodeIds\": [],\n  \"searchSourceUrls\": false\n}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/baseUrl/api/v1/w/:wId/search", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/search"

payload = {
    "query": "",
    "includeDataSources": False,
    "viewType": "",
    "spaceIds": [],
    "nodeIds": [],
    "searchSourceUrls": False
}
headers = {"content-type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/search"

payload <- "{\n  \"query\": \"\",\n  \"includeDataSources\": false,\n  \"viewType\": \"\",\n  \"spaceIds\": [],\n  \"nodeIds\": [],\n  \"searchSourceUrls\": false\n}"

encode <- "json"

response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/search")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\n  \"query\": \"\",\n  \"includeDataSources\": false,\n  \"viewType\": \"\",\n  \"spaceIds\": [],\n  \"nodeIds\": [],\n  \"searchSourceUrls\": false\n}"

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/json'}
)

response = conn.post('/baseUrl/api/v1/w/:wId/search') do |req|
  req.body = "{\n  \"query\": \"\",\n  \"includeDataSources\": false,\n  \"viewType\": \"\",\n  \"spaceIds\": [],\n  \"nodeIds\": [],\n  \"searchSourceUrls\": false\n}"
end

puts response.status
puts response.body
use serde_json::json;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/search";

    let payload = json!({
        "query": "",
        "includeDataSources": false,
        "viewType": "",
        "spaceIds": (),
        "nodeIds": (),
        "searchSourceUrls": false
    });

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("content-type", "application/json".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.post(url)
        .headers(headers)
        .json(&payload)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request POST \
  --url {{baseUrl}}/api/v1/w/:wId/search \
  --header 'content-type: application/json' \
  --data '{
  "query": "",
  "includeDataSources": false,
  "viewType": "",
  "spaceIds": [],
  "nodeIds": [],
  "searchSourceUrls": false
}'
echo '{
  "query": "",
  "includeDataSources": false,
  "viewType": "",
  "spaceIds": [],
  "nodeIds": [],
  "searchSourceUrls": false
}' |  \
  http POST {{baseUrl}}/api/v1/w/:wId/search \
  content-type:application/json
wget --quiet \
  --method POST \
  --header 'content-type: application/json' \
  --body-data '{\n  "query": "",\n  "includeDataSources": false,\n  "viewType": "",\n  "spaceIds": [],\n  "nodeIds": [],\n  "searchSourceUrls": false\n}' \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/search
import Foundation

let headers = ["content-type": "application/json"]
let parameters = [
  "query": "",
  "includeDataSources": false,
  "viewType": "",
  "spaceIds": [],
  "nodeIds": [],
  "searchSourceUrls": false
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/search")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
GET List available spaces.
{{baseUrl}}/api/v1/w/:wId/spaces
QUERY PARAMS

wId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/spaces")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces"

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/spaces HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/spaces")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces"))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/spaces")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/spaces');

xhr.send(data);
import axios from 'axios';

const options = {method: 'GET', url: '{{baseUrl}}/api/v1/w/:wId/spaces'};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {method: 'GET', url: '{{baseUrl}}/api/v1/w/:wId/spaces'};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/spaces');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {method: 'GET', url: '{{baseUrl}}/api/v1/w/:wId/spaces'};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/spaces');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces');
$request->setMethod(HTTP_METH_GET);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/spaces")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces"

response = requests.get(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces"

response <- VERB("GET", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/spaces') do |req|
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces";

    let client = reqwest::Client::new();
    let response = client.get(url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/api/v1/w/:wId/spaces
http GET {{baseUrl}}/api/v1/w/:wId/spaces
wget --quiet \
  --method GET \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
GET List available MCP server views.
{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views
QUERY PARAMS

wId
spaceId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views")
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views"

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views"),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views"

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/spaces/:spaceId/mcp_server_views HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views"))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/spaces/:spaceId/mcp_server_views',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views'
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views');

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views'
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views');
$request->setMethod(HTTP_METH_GET);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views');
$request->setRequestMethod('GET');
$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/spaces/:spaceId/mcp_server_views")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views"

response = requests.get(url)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views"

response <- VERB("GET", url, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/spaces/:spaceId/mcp_server_views') do |req|
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views";

    let client = reqwest::Client::new();
    let response = client.get(url)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views
http GET {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views
wget --quiet \
  --method GET \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/spaces/:spaceId/mcp_server_views")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
POST Receive external webhook to trigger flows
{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId
QUERY PARAMS

wId
webhookSourceId
BODY json

{}
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "POST");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "content-type: application/json");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);

curl_easy_setopt(hnd, CURLOPT_POSTFIELDS, "{}");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/post "{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId" {:content-type :json})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId"
headers = HTTP::Headers{
  "content-type" => "application/json"
}
reqBody = "{}"

response = HTTP::Client.post url, headers: headers, body: reqBody
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Post,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId"),
    Content = new StringContent("{}")
    {
        Headers =
        {
            ContentType = new MediaTypeHeaderValue("application/json")
        }
    }
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId");
var request = new RestRequest("", Method.Post);
request.AddHeader("content-type", "application/json");
request.AddParameter("application/json", "{}", ParameterType.RequestBody);
var response = client.Execute(request);
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId"

	payload := strings.NewReader("{}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("content-type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
POST /baseUrl/api/v1/w/:wId/triggers/hooks/:webhookSourceId HTTP/1.1
Content-Type: application/json
Host: example.com
Content-Length: 2

{}
AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("POST", "{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId")
  .setHeader("content-type", "application/json")
  .setBody("{}")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId"))
    .header("content-type", "application/json")
    .method("POST", HttpRequest.BodyPublishers.ofString("{}"))
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{}");
Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId")
  .post(body)
  .addHeader("content-type", "application/json")
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.post("{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId")
  .header("content-type", "application/json")
  .body("{}")
  .asString();
const data = JSON.stringify({});

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('POST', '{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId');
xhr.setRequestHeader('content-type', 'application/json');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId',
  headers: {'content-type': 'application/json'},
  data: {}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId';
const options = {method: 'POST', headers: {'content-type': 'application/json'}, body: '{}'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId',
  method: 'POST',
  headers: {
    'content-type': 'application/json'
  },
  processData: false,
  data: '{}'
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val mediaType = MediaType.parse("application/json")
val body = RequestBody.create(mediaType, "{}")
val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId")
  .post(body)
  .addHeader("content-type", "application/json")
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'POST',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/triggers/hooks/:webhookSourceId',
  headers: {
    'content-type': 'application/json'
  }
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.write(JSON.stringify({}));
req.end();
const request = require('request');

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId',
  headers: {'content-type': 'application/json'},
  body: {},
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('POST', '{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId');

req.headers({
  'content-type': 'application/json'
});

req.type('json');
req.send({});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'POST',
  url: '{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId',
  headers: {'content-type': 'application/json'},
  data: {}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId';
const options = {method: 'POST', headers: {'content-type': 'application/json'}, body: '{}'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSDictionary *headers = @{ @"content-type": @"application/json" };
NSDictionary *parameters = @{  };

NSData *postData = [NSJSONSerialization dataWithJSONObject:parameters options:0 error:nil];

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId"]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"POST"];
[request setAllHTTPHeaderFields:headers];
[request setHTTPBody:postData];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId" in
let headers = Header.add (Header.init ()) "content-type" "application/json" in
let body = Cohttp_lwt_body.of_string "{}" in

Client.call ~headers ~body `POST uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => json_encode([
    
  ]),
  CURLOPT_HTTPHEADER => [
    "content-type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('POST', '{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId', [
  'body' => '{}',
  'headers' => [
    'content-type' => 'application/json',
  ],
]);

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId');
$request->setMethod(HTTP_METH_POST);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$request->setContentType('application/json');
$request->setBody(json_encode([
  
]));

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
append(json_encode([
  
]));
$request->setRequestUrl('{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId');
$request->setRequestMethod('POST');
$request->setBody($body);

$request->setHeaders([
  'content-type' => 'application/json'
]);

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId' -Method POST -Headers $headers -ContentType 'application/json' -Body '{}'
$headers=@{}
$headers.Add("content-type", "application/json")
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId' -Method POST -Headers $headers -ContentType 'application/json' -Body '{}'
import http.client

conn = http.client.HTTPSConnection("example.com")

payload = "{}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/baseUrl/api/v1/w/:wId/triggers/hooks/:webhookSourceId", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId"

payload = {}
headers = {"content-type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId"

payload <- "{}"

encode <- "json"

response <- VERB("POST", url, body = payload, content_type("application/json"), encode = encode)

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{}"

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
  headers: {'Content-Type' => 'application/json'}
)

response = conn.post('/baseUrl/api/v1/w/:wId/triggers/hooks/:webhookSourceId') do |req|
  req.body = "{}"
end

puts response.status
puts response.body
use serde_json::json;
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId";

    let payload = json!({});

    let mut headers = reqwest::header::HeaderMap::new();
    headers.insert("content-type", "application/json".parse().unwrap());

    let client = reqwest::Client::new();
    let response = client.post(url)
        .headers(headers)
        .json(&payload)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request POST \
  --url {{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId \
  --header 'content-type: application/json' \
  --data '{}'
echo '{}' |  \
  http POST {{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId \
  content-type:application/json
wget --quiet \
  --method POST \
  --header 'content-type: application/json' \
  --body-data '{}' \
  --output-document \
  - {{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId
import Foundation

let headers = ["content-type": "application/json"]
let parameters = [] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/triggers/hooks/:webhookSourceId")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
GET Get workspace usage data
{{baseUrl}}/api/v1/w/:wId/workspace-usage
QUERY PARAMS

start
mode
table
wId
Examples
REQUEST

CURL *hnd = curl_easy_init();

curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table=");

CURLcode ret = curl_easy_perform(hnd);
(require '[clj-http.client :as client])

(client/get "{{baseUrl}}/api/v1/w/:wId/workspace-usage" {:query-params {:start ""
                                                                                        :mode ""
                                                                                        :table ""}})
require "http/client"

url = "{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table="

response = HTTP::Client.get url
puts response.body
using System.Net.Http.Headers;
var client = new HttpClient();
var request = new HttpRequestMessage
{
    Method = HttpMethod.Get,
    RequestUri = new Uri("{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table="),
};
using (var response = await client.SendAsync(request))
{
    response.EnsureSuccessStatusCode();
    var body = await response.Content.ReadAsStringAsync();
    Console.WriteLine(body);
}
var client = new RestClient("{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table=");
var request = new RestRequest("", Method.Get);
var response = client.Execute(request);
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table="

	req, _ := http.NewRequest("GET", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
GET /baseUrl/api/v1/w/:wId/workspace-usage?start=&mode=&table= HTTP/1.1
Host: example.com

AsyncHttpClient client = new DefaultAsyncHttpClient();
client.prepare("GET", "{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table=")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table="))
    .method("GET", HttpRequest.BodyPublishers.noBody())
    .build();
HttpResponse response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
OkHttpClient client = new OkHttpClient();

Request request = new Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table=")
  .get()
  .build();

Response response = client.newCall(request).execute();
HttpResponse response = Unirest.get("{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table=")
  .asString();
const data = null;

const xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener('readystatechange', function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open('GET', '{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table=');

xhr.send(data);
import axios from 'axios';

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/workspace-usage',
  params: {start: '', mode: '', table: ''}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const url = '{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table=';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
const settings = {
  async: true,
  crossDomain: true,
  url: '{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table=',
  method: 'GET',
  headers: {}
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
val client = OkHttpClient()

val request = Request.Builder()
  .url("{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table=")
  .get()
  .build()

val response = client.newCall(request).execute()
const http = require('https');

const options = {
  method: 'GET',
  hostname: 'example.com',
  port: null,
  path: '/baseUrl/api/v1/w/:wId/workspace-usage?start=&mode=&table=',
  headers: {}
};

const req = http.request(options, function (res) {
  const chunks = [];

  res.on('data', function (chunk) {
    chunks.push(chunk);
  });

  res.on('end', function () {
    const body = Buffer.concat(chunks);
    console.log(body.toString());
  });
});

req.end();
const request = require('request');

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/workspace-usage',
  qs: {start: '', mode: '', table: ''}
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
});
const unirest = require('unirest');

const req = unirest('GET', '{{baseUrl}}/api/v1/w/:wId/workspace-usage');

req.query({
  start: '',
  mode: '',
  table: ''
});

req.end(function (res) {
  if (res.error) throw new Error(res.error);

  console.log(res.body);
});
const axios = require('axios').default;

const options = {
  method: 'GET',
  url: '{{baseUrl}}/api/v1/w/:wId/workspace-usage',
  params: {start: '', mode: '', table: ''}
};

try {
  const { data } = await axios.request(options);
  console.log(data);
} catch (error) {
  console.error(error);
}
const fetch = require('node-fetch');

const url = '{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table=';
const options = {method: 'GET'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
#import 

NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table="]
                                                       cachePolicy:NSURLRequestUseProtocolCachePolicy
                                                   timeoutInterval:10.0];
[request setHTTPMethod:@"GET"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *dataTask = [session dataTaskWithRequest:request
                                            completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
                                                if (error) {
                                                    NSLog(@"%@", error);
                                                } else {
                                                    NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *) response;
                                                    NSLog(@"%@", httpResponse);
                                                }
                                            }];
[dataTask resume];
open Cohttp_lwt_unix
open Cohttp
open Lwt

let uri = Uri.of_string "{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table=" in

Client.call `GET uri
>>= fun (res, body_stream) ->
  (* Do stuff with the result *)
 "{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table=",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
request('GET', '{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table=');

echo $response->getBody();
setUrl('{{baseUrl}}/api/v1/w/:wId/workspace-usage');
$request->setMethod(HTTP_METH_GET);

$request->setQueryData([
  'start' => '',
  'mode' => '',
  'table' => ''
]);

try {
  $response = $request->send();

  echo $response->getBody();
} catch (HttpException $ex) {
  echo $ex;
}
setRequestUrl('{{baseUrl}}/api/v1/w/:wId/workspace-usage');
$request->setRequestMethod('GET');
$request->setQuery(new http\QueryString([
  'start' => '',
  'mode' => '',
  'table' => ''
]));

$client->enqueue($request)->send();
$response = $client->getResponse();

echo $response->getBody();
$response = Invoke-WebRequest -Uri '{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table=' -Method GET 
$response = Invoke-RestMethod -Uri '{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table=' -Method GET 
import http.client

conn = http.client.HTTPSConnection("example.com")

conn.request("GET", "/baseUrl/api/v1/w/:wId/workspace-usage?start=&mode=&table=")

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
import requests

url = "{{baseUrl}}/api/v1/w/:wId/workspace-usage"

querystring = {"start":"","mode":"","table":""}

response = requests.get(url, params=querystring)

print(response.json())
library(httr)

url <- "{{baseUrl}}/api/v1/w/:wId/workspace-usage"

queryString <- list(
  start = "",
  mode = "",
  table = ""
)

response <- VERB("GET", url, query = queryString, content_type("application/octet-stream"))

content(response, "text")
require 'uri'
require 'net/http'

url = URI("{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table=")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
require 'faraday'

conn = Faraday.new(
  url: 'https://example.com',
)

response = conn.get('/baseUrl/api/v1/w/:wId/workspace-usage') do |req|
  req.params['start'] = ''
  req.params['mode'] = ''
  req.params['table'] = ''
end

puts response.status
puts response.body
use reqwest;

#[tokio::main]
pub async fn main() {
    let url = "{{baseUrl}}/api/v1/w/:wId/workspace-usage";

    let querystring = [
        ("start", ""),
        ("mode", ""),
        ("table", ""),
    ];

    let client = reqwest::Client::new();
    let response = client.get(url)
        .query(&querystring)
        .send()
        .await;

    let results = response.unwrap()
        .json::()
        .await
        .unwrap();

    dbg!(results);
}
curl --request GET \
  --url '{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table='
http GET '{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table='
wget --quiet \
  --method GET \
  --output-document \
  - '{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table='
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "{{baseUrl}}/api/v1/w/:wId/workspace-usage?start=&mode=&table=")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()