Generate Jobs URL
curl --request POST \
--url https://cloud.cdata.com/api/poweredby/jobs \
--header 'Authorization: Bearer <token>'import requests
url = "https://cloud.cdata.com/api/poweredby/jobs"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://cloud.cdata.com/api/poweredby/jobs', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://cloud.cdata.com/api/poweredby/jobs",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://cloud.cdata.com/api/poweredby/jobs"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://cloud.cdata.com/api/poweredby/jobs")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://cloud.cdata.com/api/poweredby/jobs")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"redirectURL": "https://cloud.cdata.com/oem/user/jobs?token=eyJhbGciOiJSUzI1NiIs...truncated..."
}Job API
Generate Jobs URL
Generate Jobs URL redirects you to the Jobs page of Connect AI.
POST
/
poweredby
/
jobs
Generate Jobs URL
curl --request POST \
--url https://cloud.cdata.com/api/poweredby/jobs \
--header 'Authorization: Bearer <token>'import requests
url = "https://cloud.cdata.com/api/poweredby/jobs"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://cloud.cdata.com/api/poweredby/jobs', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://cloud.cdata.com/api/poweredby/jobs",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://cloud.cdata.com/api/poweredby/jobs"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://cloud.cdata.com/api/poweredby/jobs")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://cloud.cdata.com/api/poweredby/jobs")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"redirectURL": "https://cloud.cdata.com/oem/user/jobs?token=eyJhbGciOiJSUzI1NiIs...truncated..."
}This endpoint returns a redirect URL scoped to a sub-account, allowing Connect AI Embed administrators or sub-account users to manage cache connections and jobs through CData’s co-branded visual interface.
If you have not already done so, you must set up a PostgreSQL data warehouse for your cached data. Click Set Up Data Warehouse to view the Add Connection page for PostgreSQL. Follow the instructions.
Once you have a data warehouse set up, click Add Job to add a cache job. Follow the steps in the Add Jobs wizard to schedule the job. See Add a Cache Job for detailed instructions.
Note that when you enable caching of data, Connect AI Embed runs database queries against the cached data, not the live data. See Caching for a complete overview of the Caching feature.
Authorizations
JWT token authentication. Include the token in the Authorization header as Bearer {token}. See Authentication for more information on creating a token.
Response
200 - application/json
A string containing the URL to redirect the user to.
A string containing the CData-hosted connection URL to redirect the user to.
Was this page helpful?