Skip to main content
PUT
/
rr
/
api
/
v1
/
product-bundles
/
{id}
Update Product Bundle
curl --request PUT \
  --url https://api.meetcampfire.com/rr/api/v1/product-bundles/{id} \
  --header 'Authorization: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "bundle_name": "<string>",
  "lines": [
    {
      "product": 123,
      "percentage_allocation": 50.005
    }
  ],
  "bundle_description": "<string>",
  "stripe_product_id": "<string>"
}
'
import requests

url = "https://api.meetcampfire.com/rr/api/v1/product-bundles/{id}"

payload = {
"bundle_name": "<string>",
"lines": [
{
"product": 123,
"percentage_allocation": 50.005
}
],
"bundle_description": "<string>",
"stripe_product_id": "<string>"
}
headers = {
"Authorization": "<api-key>",
"Content-Type": "application/json"
}

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

print(response.text)
const options = {
method: 'PUT',
headers: {Authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
bundle_name: '<string>',
lines: [{product: 123, percentage_allocation: 50.005}],
bundle_description: '<string>',
stripe_product_id: '<string>'
})
};

fetch('https://api.meetcampfire.com/rr/api/v1/product-bundles/{id}', 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.meetcampfire.com/rr/api/v1/product-bundles/{id}",
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([
'bundle_name' => '<string>',
'lines' => [
[
'product' => 123,
'percentage_allocation' => 50.005
]
],
'bundle_description' => '<string>',
'stripe_product_id' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"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.meetcampfire.com/rr/api/v1/product-bundles/{id}"

payload := strings.NewReader("{\n \"bundle_name\": \"<string>\",\n \"lines\": [\n {\n \"product\": 123,\n \"percentage_allocation\": 50.005\n }\n ],\n \"bundle_description\": \"<string>\",\n \"stripe_product_id\": \"<string>\"\n}")

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

req.Header.Add("Authorization", "<api-key>")
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://api.meetcampfire.com/rr/api/v1/product-bundles/{id}")
.header("Authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"bundle_name\": \"<string>\",\n \"lines\": [\n {\n \"product\": 123,\n \"percentage_allocation\": 50.005\n }\n ],\n \"bundle_description\": \"<string>\",\n \"stripe_product_id\": \"<string>\"\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.meetcampfire.com/rr/api/v1/product-bundles/{id}")

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

request = Net::HTTP::Put.new(url)
request["Authorization"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"bundle_name\": \"<string>\",\n \"lines\": [\n {\n \"product\": 123,\n \"percentage_allocation\": 50.005\n }\n ],\n \"bundle_description\": \"<string>\",\n \"stripe_product_id\": \"<string>\"\n}"

response = http.request(request)
puts response.read_body
{
  "id": 123,
  "bundle_name": "<string>",
  "anrok_item_id": "<string>",
  "lines": [
    {
      "id": 123,
      "product": 123,
      "product_name": "<string>",
      "product_id_str": "<string>",
      "percentage_allocation": 50.005
    }
  ],
  "created_at": "2023-11-07T05:31:56Z",
  "last_modified_at": "2023-11-07T05:31:56Z",
  "is_deleted": false,
  "deleted_at": "2023-11-07T05:31:56Z",
  "bundle_description": "<string>",
  "stripe_product_id": "<string>"
}

Authorizations

Authorization
string
header
required

Token-based authentication with required prefix "Token"

Path Parameters

id
integer
required

Body

bundle_name
string
required
Maximum string length: 250
lines
object[]
required
bundle_description
string | null
Maximum string length: 250
stripe_product_id
string | null
Maximum string length: 255

Response

200 - application/json
id
integer
required
read-only
bundle_name
string
required
Maximum string length: 250
anrok_item_id
string | null
required
read-only
lines
object[]
required
created_at
string<date-time>
required
read-only
last_modified_at
string<date-time>
required
read-only
is_deleted
boolean
default:false
required
read-only
deleted_at
string<date-time> | null
required
read-only
bundle_description
string | null
Maximum string length: 250
stripe_product_id
string | null
Maximum string length: 255