Create TPA Plan
curl --request POST \
--url https://api.stax.ai/tpa/plan/create \
--header 'Content-Type: application/json' \
--cookie authToken= \
--data '
{
"planName": "<string>",
"planType": "<string>",
"internalPlanId": "<string>",
"pensionProId": 123,
"endMm": 123,
"endDd": 123,
"active": true,
"directory": "<string>"
}
'import requests
url = "https://api.stax.ai/tpa/plan/create"
payload = {
"planName": "<string>",
"planType": "<string>",
"internalPlanId": "<string>",
"pensionProId": 123,
"endMm": 123,
"endDd": 123,
"active": True,
"directory": "<string>"
}
headers = {
"cookie": "authToken=",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {cookie: 'authToken=', 'Content-Type': 'application/json'},
body: JSON.stringify({
planName: '<string>',
planType: '<string>',
internalPlanId: '<string>',
pensionProId: 123,
endMm: 123,
endDd: 123,
active: true,
directory: '<string>'
})
};
fetch('https://api.stax.ai/tpa/plan/create', 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://api.stax.ai/tpa/plan/create",
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([
'planName' => '<string>',
'planType' => '<string>',
'internalPlanId' => '<string>',
'pensionProId' => 123,
'endMm' => 123,
'endDd' => 123,
'active' => true,
'directory' => '<string>'
]),
CURLOPT_COOKIE => "authToken=",
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;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.stax.ai/tpa/plan/create"
payload := strings.NewReader("{\n \"planName\": \"<string>\",\n \"planType\": \"<string>\",\n \"internalPlanId\": \"<string>\",\n \"pensionProId\": 123,\n \"endMm\": 123,\n \"endDd\": 123,\n \"active\": true,\n \"directory\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("cookie", "authToken=")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.stax.ai/tpa/plan/create")
.header("cookie", "authToken=")
.header("Content-Type", "application/json")
.body("{\n \"planName\": \"<string>\",\n \"planType\": \"<string>\",\n \"internalPlanId\": \"<string>\",\n \"pensionProId\": 123,\n \"endMm\": 123,\n \"endDd\": 123,\n \"active\": true,\n \"directory\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.stax.ai/tpa/plan/create")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["cookie"] = 'authToken='
request["Content-Type"] = 'application/json'
request.body = "{\n \"planName\": \"<string>\",\n \"planType\": \"<string>\",\n \"internalPlanId\": \"<string>\",\n \"pensionProId\": 123,\n \"endMm\": 123,\n \"endDd\": 123,\n \"active\": true,\n \"directory\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"plan": {
"_id": "<string>",
"team": "<string>",
"pensionProId": 123,
"internalPlanId": "<string>",
"planName": "<string>",
"planType": "<string>",
"endMm": 123,
"endDd": 123,
"active": true,
"directory": "<string>",
"ppLock": true,
"search": [
"<string>"
],
"notes": [
{
"author": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"content": "<string>"
}
],
"lastModified": "2023-11-07T05:31:56Z",
"assignees": [
"<string>"
],
"status": {}
}
}TPA
Create TPA Plan
Create a new TPA plan
POST
/
tpa
/
plan
/
create
Create TPA Plan
curl --request POST \
--url https://api.stax.ai/tpa/plan/create \
--header 'Content-Type: application/json' \
--cookie authToken= \
--data '
{
"planName": "<string>",
"planType": "<string>",
"internalPlanId": "<string>",
"pensionProId": 123,
"endMm": 123,
"endDd": 123,
"active": true,
"directory": "<string>"
}
'import requests
url = "https://api.stax.ai/tpa/plan/create"
payload = {
"planName": "<string>",
"planType": "<string>",
"internalPlanId": "<string>",
"pensionProId": 123,
"endMm": 123,
"endDd": 123,
"active": True,
"directory": "<string>"
}
headers = {
"cookie": "authToken=",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {cookie: 'authToken=', 'Content-Type': 'application/json'},
body: JSON.stringify({
planName: '<string>',
planType: '<string>',
internalPlanId: '<string>',
pensionProId: 123,
endMm: 123,
endDd: 123,
active: true,
directory: '<string>'
})
};
fetch('https://api.stax.ai/tpa/plan/create', 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://api.stax.ai/tpa/plan/create",
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([
'planName' => '<string>',
'planType' => '<string>',
'internalPlanId' => '<string>',
'pensionProId' => 123,
'endMm' => 123,
'endDd' => 123,
'active' => true,
'directory' => '<string>'
]),
CURLOPT_COOKIE => "authToken=",
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;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.stax.ai/tpa/plan/create"
payload := strings.NewReader("{\n \"planName\": \"<string>\",\n \"planType\": \"<string>\",\n \"internalPlanId\": \"<string>\",\n \"pensionProId\": 123,\n \"endMm\": 123,\n \"endDd\": 123,\n \"active\": true,\n \"directory\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("cookie", "authToken=")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.stax.ai/tpa/plan/create")
.header("cookie", "authToken=")
.header("Content-Type", "application/json")
.body("{\n \"planName\": \"<string>\",\n \"planType\": \"<string>\",\n \"internalPlanId\": \"<string>\",\n \"pensionProId\": 123,\n \"endMm\": 123,\n \"endDd\": 123,\n \"active\": true,\n \"directory\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.stax.ai/tpa/plan/create")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["cookie"] = 'authToken='
request["Content-Type"] = 'application/json'
request.body = "{\n \"planName\": \"<string>\",\n \"planType\": \"<string>\",\n \"internalPlanId\": \"<string>\",\n \"pensionProId\": 123,\n \"endMm\": 123,\n \"endDd\": 123,\n \"active\": true,\n \"directory\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"plan": {
"_id": "<string>",
"team": "<string>",
"pensionProId": 123,
"internalPlanId": "<string>",
"planName": "<string>",
"planType": "<string>",
"endMm": 123,
"endDd": 123,
"active": true,
"directory": "<string>",
"ppLock": true,
"search": [
"<string>"
],
"notes": [
{
"author": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"content": "<string>"
}
],
"lastModified": "2023-11-07T05:31:56Z",
"assignees": [
"<string>"
],
"status": {}
}
}Authorizations
cookieAuthbearerAuth
Cookie-based authentication using userId and authToken cookies
Body
application/json
⌘I