Register an AWS Marketplace agreement
curl --request POST \
--url https://us.api.flexprice.io/v1/marketplace/agreements \
--header 'Content-Type: application/json' \
--data '
{
"customer_aws_account_id": "<string>",
"customer_id": "<string>",
"dimension": "<string>",
"license_arn": "<string>",
"plan_id": "<string>",
"product_code": "<string>",
"provider": "<string>",
"subscription_id": "<string>",
"concurrent_agreements": true
}
'import requests
url = "https://us.api.flexprice.io/v1/marketplace/agreements"
payload = {
"customer_aws_account_id": "<string>",
"customer_id": "<string>",
"dimension": "<string>",
"license_arn": "<string>",
"plan_id": "<string>",
"product_code": "<string>",
"provider": "<string>",
"subscription_id": "<string>",
"concurrent_agreements": True
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
customer_aws_account_id: '<string>',
customer_id: '<string>',
dimension: '<string>',
license_arn: '<string>',
plan_id: '<string>',
product_code: '<string>',
provider: '<string>',
subscription_id: '<string>',
concurrent_agreements: true
})
};
fetch('https://us.api.flexprice.io/v1/marketplace/agreements', 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://us.api.flexprice.io/v1/marketplace/agreements",
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([
'customer_aws_account_id' => '<string>',
'customer_id' => '<string>',
'dimension' => '<string>',
'license_arn' => '<string>',
'plan_id' => '<string>',
'product_code' => '<string>',
'provider' => '<string>',
'subscription_id' => '<string>',
'concurrent_agreements' => true
]),
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://us.api.flexprice.io/v1/marketplace/agreements"
payload := strings.NewReader("{\n \"customer_aws_account_id\": \"<string>\",\n \"customer_id\": \"<string>\",\n \"dimension\": \"<string>\",\n \"license_arn\": \"<string>\",\n \"plan_id\": \"<string>\",\n \"product_code\": \"<string>\",\n \"provider\": \"<string>\",\n \"subscription_id\": \"<string>\",\n \"concurrent_agreements\": true\n}")
req, _ := http.NewRequest("POST", url, payload)
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://us.api.flexprice.io/v1/marketplace/agreements")
.header("Content-Type", "application/json")
.body("{\n \"customer_aws_account_id\": \"<string>\",\n \"customer_id\": \"<string>\",\n \"dimension\": \"<string>\",\n \"license_arn\": \"<string>\",\n \"plan_id\": \"<string>\",\n \"product_code\": \"<string>\",\n \"provider\": \"<string>\",\n \"subscription_id\": \"<string>\",\n \"concurrent_agreements\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://us.api.flexprice.io/v1/marketplace/agreements")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"customer_aws_account_id\": \"<string>\",\n \"customer_id\": \"<string>\",\n \"dimension\": \"<string>\",\n \"license_arn\": \"<string>\",\n \"plan_id\": \"<string>\",\n \"product_code\": \"<string>\",\n \"provider\": \"<string>\",\n \"subscription_id\": \"<string>\",\n \"concurrent_agreements\": true\n}"
response = http.request(request)
puts response.read_body{
"customer_mapping_id": "<string>",
"plan_mapping_id": "<string>",
"status": "<string>",
"subscription_mapping_id": "<string>"
}Marketplace
Register an AWS Marketplace agreement
Registers an AWS Marketplace buyer agreement against an existing FlexPrice subscription, upserting plan/subscription/customer integration mappings in one call.
POST
/
marketplace
/
agreements
Register an AWS Marketplace agreement
curl --request POST \
--url https://us.api.flexprice.io/v1/marketplace/agreements \
--header 'Content-Type: application/json' \
--data '
{
"customer_aws_account_id": "<string>",
"customer_id": "<string>",
"dimension": "<string>",
"license_arn": "<string>",
"plan_id": "<string>",
"product_code": "<string>",
"provider": "<string>",
"subscription_id": "<string>",
"concurrent_agreements": true
}
'import requests
url = "https://us.api.flexprice.io/v1/marketplace/agreements"
payload = {
"customer_aws_account_id": "<string>",
"customer_id": "<string>",
"dimension": "<string>",
"license_arn": "<string>",
"plan_id": "<string>",
"product_code": "<string>",
"provider": "<string>",
"subscription_id": "<string>",
"concurrent_agreements": True
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
customer_aws_account_id: '<string>',
customer_id: '<string>',
dimension: '<string>',
license_arn: '<string>',
plan_id: '<string>',
product_code: '<string>',
provider: '<string>',
subscription_id: '<string>',
concurrent_agreements: true
})
};
fetch('https://us.api.flexprice.io/v1/marketplace/agreements', 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://us.api.flexprice.io/v1/marketplace/agreements",
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([
'customer_aws_account_id' => '<string>',
'customer_id' => '<string>',
'dimension' => '<string>',
'license_arn' => '<string>',
'plan_id' => '<string>',
'product_code' => '<string>',
'provider' => '<string>',
'subscription_id' => '<string>',
'concurrent_agreements' => true
]),
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://us.api.flexprice.io/v1/marketplace/agreements"
payload := strings.NewReader("{\n \"customer_aws_account_id\": \"<string>\",\n \"customer_id\": \"<string>\",\n \"dimension\": \"<string>\",\n \"license_arn\": \"<string>\",\n \"plan_id\": \"<string>\",\n \"product_code\": \"<string>\",\n \"provider\": \"<string>\",\n \"subscription_id\": \"<string>\",\n \"concurrent_agreements\": true\n}")
req, _ := http.NewRequest("POST", url, payload)
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://us.api.flexprice.io/v1/marketplace/agreements")
.header("Content-Type", "application/json")
.body("{\n \"customer_aws_account_id\": \"<string>\",\n \"customer_id\": \"<string>\",\n \"dimension\": \"<string>\",\n \"license_arn\": \"<string>\",\n \"plan_id\": \"<string>\",\n \"product_code\": \"<string>\",\n \"provider\": \"<string>\",\n \"subscription_id\": \"<string>\",\n \"concurrent_agreements\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://us.api.flexprice.io/v1/marketplace/agreements")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"customer_aws_account_id\": \"<string>\",\n \"customer_id\": \"<string>\",\n \"dimension\": \"<string>\",\n \"license_arn\": \"<string>\",\n \"plan_id\": \"<string>\",\n \"product_code\": \"<string>\",\n \"provider\": \"<string>\",\n \"subscription_id\": \"<string>\",\n \"concurrent_agreements\": true\n}"
response = http.request(request)
puts response.read_body{
"customer_mapping_id": "<string>",
"plan_mapping_id": "<string>",
"status": "<string>",
"subscription_mapping_id": "<string>"
}Body
application/json
Agreement registration request
⌘I

