Get terms & conditions status - Fabric
Get terms & conditions status
cURL
curl --request GET \
--url https://marketplace-api.fabric.inc/v1/retailers/{retailer_id}/connections/t-and-c-status/ \
--header 'Authorization: Bearer <token>'
Python
import requests
url = "https://marketplace-api.fabric.inc/v1/retailers/{retailer_id}/connections/t-and-c-status/"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)
JavaScript (Fetch)
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://marketplace-api.fabric.inc/v1/retailers/{retailer_id}/connections/t-and-c-status/', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
PHP
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://marketplace-api.fabric.inc/v1/retailers/{retailer_id}/connections/t-and-c-status/",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
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;
}
?>
Go
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://marketplace-api.fabric.inc/v1/retailers/{retailer_id}/connections/t-and-c-status/"
req, _ := http.NewRequest("GET", 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))
}
Unirest (Java)
HttpResponse<String> response = Unirest.get("https://marketplace-api.fabric.inc/v1/retailers/{retailer_id}/connections/t-and-c-status/")
.header("Authorization", "Bearer <token>")
.asString();
Ruby
require 'uri'
require 'net/http'
url = URI("https://marketplace-api.fabric.inc/v1/retailers/{retailer_id}/connections/t-and-c-status/")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body
Response
200
{
"count": 3,
"results": [
{
"brand": "TechCorp",
"retailer": "Retailer X",
"level": "transactions_and_products",
"status": "active",
"id": 12345,
"suspended_at": "2024-04-01T12:00:00Z",
"created_at": "2024-03-01T12:00:00Z",
"updated_at": "2024-04-01T12:00:00Z",
"shipping_accounts": "FedEx, UPS",
"options": "Gift Wrapping Available",
"attachments": "Attachment1.pdf",
"approved_items_count": "5",
"orders_last_7_days_count": "10",
"proposals_received_last_7_days_count": "3",
"contacts": "contact1@example.com, contact2@example.com",
"memos": "Terms accepted on 2024-03-01.",
"referral": "Referred by John Doe",
"commission_profile": "Standard Commission",
"integration_type": "api",
"onboarding_status": "pending",
"retailer_identifier": "Retailer-01",
"onboarding_target_date": "2024-04-30T00:00:00Z",
"intro_call_date": "2024-03-01T12:00:00Z",
"onboarded_at": "2024-03-15T12:00:00Z",
"onboarding_steps": "Step 1: Account Setup, Step 2: Review Terms"
}
],
"next": "https://api.example.org/demo/accounts/?page=2",
"previous": "https://api.example.org/demo/accounts/?page=1"
}
Authorizations
Authorization
string header required
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
retailer_id
integer required
The unique retailer ID. In the Dropship UI this is called the Merchant ID. To find your Merchant ID, click your merchant name in the top nav.
Example:
1001
Response
200 - application/json
count
integer required
Total number of records
Example:
3
results
object[] required
Show child attributes
next
string
Next page (applicable in a paginated response)
Example:
"https://api.example.org/demo/accounts/?page=2"
previous
string
Previous page (applicable in a paginated response)
Example:
"https://api.example.org/demo/accounts/?page=1"