Path parameters
-
UserBubbleId
string Required User Unique Bubble ID
-
OriginCode
string Required Origin Unique Code
Body
Required
Origin to upsert into database. 'id' should NOT be in the payload. If the given 'nrn' already exists, the Origin will be updated. If a field is not present in the payload, it won't be updated. If you want to erase a field, you have to send a nullish value.
-
bubbleId
string Bubble unique ID of the Origin. It can be null if the Origin was not created on Bubble at first.
-
sellerBubbleId
string Bubble unique ID of the Seller. It can be null if the Seller was not created on Bubble at first.
-
sellerId
string -
type
string -
code
string -
logo
string -
companyName
string -
companyAddress
string -
companyAddressComplement
string -
companyCity
string -
companyZipCode
string -
companyCountry
string -
companyCountryId
string Database UUID of the country
-
brandName
string -
welcomeEN
string -
welcomeFR
string -
referralFeesPercentage
number -
creditsDiscountedPrice
number -
contact
string -
createdAt
string -
updatedAt
string
POST
/users/{UserBubbleId}/origins/{OriginCode}
curl \
--request POST 'https://b6l4r8pq7c.execute-api.eu-west-3.amazonaws.com/users/1708861331497x933611102973227500/origins/FDE789' \
--header "Authorization: $API_KEY" \
--header "Content-Type: application/json" \
--data '{"bubbleId":"1708861331497x933611102973227500","sellerBubbleId":"1708861331497x933611102973227500","sellerId":"50658c1e-356e-4407-b120-d110552292d8","type":"Distributor","code":"C24O22M24","logo":"https://url-to-logo","companyName":"Coca-Cola","companyAddress":"54 RUE Voltaire","companyAddressComplement":"Bat A, Appt 124","companyCity":"Montpellier","companyZipCode":"34000","companyCountry":"France","companyCountryId":"50658c1e-356e-4407-b120-d110552292d8","brandName":"Coca-Cola Zero","welcomeEN":"Welcome To Coca Cola","welcomeFR":"Welcome To Coca Cola","referralFeesPercentage":20,"creditsDiscountedPrice":1.56,"contact":"https://my-contract.com","createdAt":"2024-01-19T12:45:04.147Z","updatedAt":"2024-01-19T12:45:04.147Z"}'
Request examples
{
"bubbleId": "1708861331497x933611102973227500",
"sellerBubbleId": "1708861331497x933611102973227500",
"sellerId": "50658c1e-356e-4407-b120-d110552292d8",
"type": "Distributor",
"code": "C24O22M24",
"logo": "https://url-to-logo",
"companyName": "Coca-Cola",
"companyAddress": "54 RUE Voltaire",
"companyAddressComplement": "Bat A, Appt 124",
"companyCity": "Montpellier",
"companyZipCode": "34000",
"companyCountry": "France",
"companyCountryId": "50658c1e-356e-4407-b120-d110552292d8",
"brandName": "Coca-Cola Zero",
"welcomeEN": "Welcome To Coca Cola",
"welcomeFR": "Welcome To Coca Cola",
"referralFeesPercentage": 20,
"creditsDiscountedPrice": 1.56,
"contact": "https://my-contract.com",
"createdAt": "2024-01-19T12:45:04.147Z",
"updatedAt": "2024-01-19T12:45:04.147Z"
}
Response examples (200)
{
"id": "50658c1e-356e-4407-b120-d110552292d8",
"bubbleId": "1708861331497x933611102973227500",
"companyName": "Coca-Cola",
"nrn": "45649879465",
"vat": "FR95645645678",
"companyAddress": "42 RUE VICTOR HUGO",
"companyLogo": "https://my-url",
"superAdminEmail": "super-admin@email.com",
"superAdminMobilePhone": "0609921214",
"superAdminFirstName": "Nicolas",
"superAdminLastName": "Delalande",
"registrationFeesId": "string",
"declarationBasicFeesId": "string",
"declarationPremiumFeesId": "string",
"connectAlgorepId": "string",
"commissionPercentage": "string",
"createdAt": "2024-01-19T12:45:04.147Z",
"updatedAt": "2024-01-19T12:45:04.147Z"
}
Response examples (400)
{
"error": "ALGOREP_001"
}
Response examples (500)
{
"error": "ALGOREP_001"
}