Skip to main content
PUT
/
v1
/
retailers
/
{retailer_pk}
/
permits
/
{id}
/
acknowledge
/
Acknowledge receipt of a new permit
curl --request PUT \
  --url https://marketplace-api.fabric.inc/v1/retailers/{retailer_pk}/permits/{id}/acknowledge/ \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "variant": {
    "name": "Var45",
    "identifier": "123-DEF12345",
    "upc": 555555555202,
    "retailer_identifiers": [
      {
        "identifier": "SKU976",
        "name": "Retailer Sample"
      }
    ]
  },
  "connection": {
    "connection_fee": {
      "payment_model": "managed",
      "payment_terms": "net60",
      "net_price_method": "permit_cost",
      "revshare_fraction": "0.4000",
      "revc_fee_flat": "0.00",
      "revc_fee_fraction": "0.0300",
      "brand_fee_flat": "0.00",
      "brand_flat_order_fee": "0.00",
      "brand_percent_order_fee": "0.0000"
    }
  },
  "retailer_price": "12.99",
  "retailer_cost": "8.99",
  "pricing": {},
  "attributes": {},
  "start_at": "2021-07-10T15:24:56Z",
  "end_at": "2022-11-10T15:24:56Z",
  "revoked_at": "2022-08-10T15:24:56Z",
  "acknowledged_at": "2022-08-10T15:24:56Z"
}
'
import requests

url = "https://marketplace-api.fabric.inc/v1/retailers/{retailer_pk}/permits/{id}/acknowledge/"

payload = {
"variant": {
"name": "Var45",
"identifier": "123-DEF12345",
"upc": 555555555202,
"retailer_identifiers": [
{
"identifier": "SKU976",
"name": "Retailer Sample"
}
]
},
"connection": { "connection_fee": {
"payment_model": "managed",
"payment_terms": "net60",
"net_price_method": "permit_cost",
"revshare_fraction": "0.4000",
"revc_fee_flat": "0.00",
"revc_fee_fraction": "0.0300",
"brand_fee_flat": "0.00",
"brand_flat_order_fee": "0.00",
"brand_percent_order_fee": "0.0000"
} },
"retailer_price": "12.99",
"retailer_cost": "8.99",
"pricing": {},
"attributes": {},
"start_at": "2021-07-10T15:24:56Z",
"end_at": "2022-11-10T15:24:56Z",
"revoked_at": "2022-08-10T15:24:56Z",
"acknowledged_at": "2022-08-10T15:24:56Z"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}

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

print(response.text)
const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
variant: {
name: 'Var45',
identifier: '123-DEF12345',
upc: 555555555202,
retailer_identifiers: [{identifier: 'SKU976', name: 'Retailer Sample'}]
},
connection: {
connection_fee: {
payment_model: 'managed',
payment_terms: 'net60',
net_price_method: 'permit_cost',
revshare_fraction: '0.4000',
revc_fee_flat: '0.00',
revc_fee_fraction: '0.0300',
brand_fee_flat: '0.00',
brand_flat_order_fee: '0.00',
brand_percent_order_fee: '0.0000'
}
},
retailer_price: '12.99',
retailer_cost: '8.99',
pricing: {},
attributes: {},
start_at: '2021-07-10T15:24:56Z',
end_at: '2022-11-10T15:24:56Z',
revoked_at: '2022-08-10T15:24:56Z',
acknowledged_at: '2022-08-10T15:24:56Z'
})
};

fetch('https://marketplace-api.fabric.inc/v1/retailers/{retailer_pk}/permits/{id}/acknowledge/', 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://marketplace-api.fabric.inc/v1/retailers/{retailer_pk}/permits/{id}/acknowledge/",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'variant' => [
'name' => 'Var45',
'identifier' => '123-DEF12345',
'upc' => 555555555202,
'retailer_identifiers' => [
[
'identifier' => 'SKU976',
'name' => 'Retailer Sample'
]
]
],
'connection' => [
'connection_fee' => [
'payment_model' => 'managed',
'payment_terms' => 'net60',
'net_price_method' => 'permit_cost',
'revshare_fraction' => '0.4000',
'revc_fee_flat' => '0.00',
'revc_fee_fraction' => '0.0300',
'brand_fee_flat' => '0.00',
'brand_flat_order_fee' => '0.00',
'brand_percent_order_fee' => '0.0000'
]
],
'retailer_price' => '12.99',
'retailer_cost' => '8.99',
'pricing' => [

],
'attributes' => [

],
'start_at' => '2021-07-10T15:24:56Z',
'end_at' => '2022-11-10T15:24:56Z',
'revoked_at' => '2022-08-10T15:24:56Z',
'acknowledged_at' => '2022-08-10T15:24:56Z'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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://marketplace-api.fabric.inc/v1/retailers/{retailer_pk}/permits/{id}/acknowledge/"

payload := strings.NewReader("{\n \"variant\": {\n \"name\": \"Var45\",\n \"identifier\": \"123-DEF12345\",\n \"upc\": 555555555202,\n \"retailer_identifiers\": [\n {\n \"identifier\": \"SKU976\",\n \"name\": \"Retailer Sample\"\n }\n ]\n },\n \"connection\": {\n \"connection_fee\": {\n \"payment_model\": \"managed\",\n \"payment_terms\": \"net60\",\n \"net_price_method\": \"permit_cost\",\n \"revshare_fraction\": \"0.4000\",\n \"revc_fee_flat\": \"0.00\",\n \"revc_fee_fraction\": \"0.0300\",\n \"brand_fee_flat\": \"0.00\",\n \"brand_flat_order_fee\": \"0.00\",\n \"brand_percent_order_fee\": \"0.0000\"\n }\n },\n \"retailer_price\": \"12.99\",\n \"retailer_cost\": \"8.99\",\n \"pricing\": {},\n \"attributes\": {},\n \"start_at\": \"2021-07-10T15:24:56Z\",\n \"end_at\": \"2022-11-10T15:24:56Z\",\n \"revoked_at\": \"2022-08-10T15:24:56Z\",\n \"acknowledged_at\": \"2022-08-10T15:24:56Z\"\n}")

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

req.Header.Add("Authorization", "Bearer <token>")
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.put("https://marketplace-api.fabric.inc/v1/retailers/{retailer_pk}/permits/{id}/acknowledge/")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"variant\": {\n \"name\": \"Var45\",\n \"identifier\": \"123-DEF12345\",\n \"upc\": 555555555202,\n \"retailer_identifiers\": [\n {\n \"identifier\": \"SKU976\",\n \"name\": \"Retailer Sample\"\n }\n ]\n },\n \"connection\": {\n \"connection_fee\": {\n \"payment_model\": \"managed\",\n \"payment_terms\": \"net60\",\n \"net_price_method\": \"permit_cost\",\n \"revshare_fraction\": \"0.4000\",\n \"revc_fee_flat\": \"0.00\",\n \"revc_fee_fraction\": \"0.0300\",\n \"brand_fee_flat\": \"0.00\",\n \"brand_flat_order_fee\": \"0.00\",\n \"brand_percent_order_fee\": \"0.0000\"\n }\n },\n \"retailer_price\": \"12.99\",\n \"retailer_cost\": \"8.99\",\n \"pricing\": {},\n \"attributes\": {},\n \"start_at\": \"2021-07-10T15:24:56Z\",\n \"end_at\": \"2022-11-10T15:24:56Z\",\n \"revoked_at\": \"2022-08-10T15:24:56Z\",\n \"acknowledged_at\": \"2022-08-10T15:24:56Z\"\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://marketplace-api.fabric.inc/v1/retailers/{retailer_pk}/permits/{id}/acknowledge/")

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

request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"variant\": {\n \"name\": \"Var45\",\n \"identifier\": \"123-DEF12345\",\n \"upc\": 555555555202,\n \"retailer_identifiers\": [\n {\n \"identifier\": \"SKU976\",\n \"name\": \"Retailer Sample\"\n }\n ]\n },\n \"connection\": {\n \"connection_fee\": {\n \"payment_model\": \"managed\",\n \"payment_terms\": \"net60\",\n \"net_price_method\": \"permit_cost\",\n \"revshare_fraction\": \"0.4000\",\n \"revc_fee_flat\": \"0.00\",\n \"revc_fee_fraction\": \"0.0300\",\n \"brand_fee_flat\": \"0.00\",\n \"brand_flat_order_fee\": \"0.00\",\n \"brand_percent_order_fee\": \"0.0000\"\n }\n },\n \"retailer_price\": \"12.99\",\n \"retailer_cost\": \"8.99\",\n \"pricing\": {},\n \"attributes\": {},\n \"start_at\": \"2021-07-10T15:24:56Z\",\n \"end_at\": \"2022-11-10T15:24:56Z\",\n \"revoked_at\": \"2022-08-10T15:24:56Z\",\n \"acknowledged_at\": \"2022-08-10T15:24:56Z\"\n}"

response = http.request(request)
puts response.read_body
{
  "id": 10004,
  "retailer": {
    "name": "Demo Retailer",
    "code": "demo-retailer",
    "id": 500,
    "logo_url": "https://images.demo.com/retailers/5ef41f6c-3361-40b7-86ce-ecd79c52e9a2/store/logo-lg.png",
    "cover_url": "https://images.sampke.com/retailers/5ef41f6c-3361-40b7-86ce-ecd79c52e9a2/store/cover.jpg",
    "profile_tile_url": "https://images.demo.com/retailers/5ef41f6c-3361-40b7-86ce-ecd79c52e9a2/store/profile-tile.jpg",
    "joined_at": "2021-08-03T17:24:12Z",
    "is_rcn_retailer": false,
    "is_onboarded": false,
    "platform": "fabric",
    "requires_subscription": "disabled",
    "brand_permit_creation_allowed": false,
    "website": "https://demoabc.com",
    "status": "active"
  },
  "variant": {
    "id": 249,
    "name": "Var45",
    "brand": {
      "code": "marla-store",
      "id": 456,
      "name": "Marla Store"
    },
    "identifier": "123-DEF12345",
    "brand_identifier": "HATR",
    "upc": 555555555202,
    "retailer_identifiers": [
      {
        "id": 5642,
        "retailer": {
          "name": "Demo Retailer",
          "code": "demo-retailer",
          "id": 500,
          "logo_url": "https://images.demo.com/retailers/5ef41f6c-3361-40b7-86ce-ecd79c52e9a2/store/logo-lg.png",
          "cover_url": "https://images.sampke.com/retailers/5ef41f6c-3361-40b7-86ce-ecd79c52e9a2/store/cover.jpg",
          "profile_tile_url": "https://images.demo.com/retailers/5ef41f6c-3361-40b7-86ce-ecd79c52e9a2/store/profile-tile.jpg",
          "joined_at": "2021-08-03T17:24:12Z",
          "is_rcn_retailer": false,
          "is_onboarded": false,
          "platform": "fabric",
          "requires_subscription": "disabled",
          "brand_permit_creation_allowed": false,
          "website": "https://demoabc.com",
          "status": "active"
        },
        "identifier": "SKU976",
        "name": "Retailer Sample"
      }
    ]
  },
  "connection": {
    "id": 1000,
    "connection_fee": {
      "id": 1000,
      "payment_model": "managed",
      "payment_terms": "net60",
      "net_price_method": "permit_cost",
      "revshare_fraction": "0.4000",
      "revc_fee_flat": "0.00",
      "revc_fee_fraction": "0.0300",
      "brand_fee_flat": "0.00",
      "brand_flat_order_fee": "0.00",
      "brand_percent_order_fee": "0.0000",
      "effective_at": "2015-10-10T00:00:00Z"
    }
  },
  "retailer_price": "12.99",
  "retailer_cost": "8.99",
  "pricing": {},
  "attributes": {},
  "start_at": "2021-07-10T15:24:56Z",
  "end_at": "2022-11-10T15:24:56Z",
  "is_in_effect": true,
  "revoked_at": "2022-08-10T15:24:56Z",
  "is_acknowledged": true,
  "acknowledged_at": "2022-08-10T15:24:56Z"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

id
integer
required

Permit ID

retailer_pk
number
required

Retailer ID

Body

application/json
retailer
object
variant
object
connection
object
retailer_price
string<decimal> | null

Retailer price

Example:

"12.99"

retailer_cost
string<decimal> | null

Retailer cost

Example:

"8.99"

pricing
object
attributes
object
start_at
string<date-time> | null

Time of permit beginning

Example:

"2021-07-10T15:24:56Z"

end_at
string<date-time> | null

Time of permit ending

Example:

"2022-11-10T15:24:56Z"

revoked_at
string<date-time> | null

Time of when permit got revoked

Example:

"2022-08-10T15:24:56Z"

acknowledged_at
string<date-time> | null

Time of permit acknowledgement (UTC format)

Example:

"2022-08-10T15:24:56Z"

Response

200 - application/json

Ok

id
integer
read-only

Permit ID

Example:

10004

retailer
object
variant
object
connection
object
retailer_price
string<decimal> | null

Retailer price

Example:

"12.99"

retailer_cost
string<decimal> | null

Retailer cost

Example:

"8.99"

pricing
object
attributes
object
start_at
string<date-time> | null

Time of permit beginning

Example:

"2021-07-10T15:24:56Z"

end_at
string<date-time> | null

Time of permit ending

Example:

"2022-11-10T15:24:56Z"

is_in_effect
boolean
read-only

true: Permit is in effect
false: Permit is not in effect

Example:

true

revoked_at
string<date-time> | null

Time of when permit got revoked

Example:

"2022-08-10T15:24:56Z"

is_acknowledged
boolean
read-only

true: Permit is acknowledged
false: Permit is not acknowledged

Example:

true

acknowledged_at
string<date-time> | null

Time of permit acknowledgement (UTC format)

Example:

"2022-08-10T15:24:56Z"