Customer Migrations Guide: Business Import
In this section we will guide you through the process of creating businesses with business contracts in Kraken.
If a business has business contracts, it must be migrated using the create business endpoint with all of its business contracts in the same payload. This must be done before any accounts associated to the business are migrated.
To link accounts to the correct business contract, the business.business_contracts.identifier
provided in the business payload must correspond to the business.business_contract_identifier
provided in the account payload.
API Endpoints
Overview
Businesses which require business contracts in Kraken can be created by providing a valid JSON payload to the following endpoint.
The business JSON payload must include essential data to uniquely identify and create a business entity and all it's business contracts.
Schema
Responses
The following responses may be returned from the API.
Status code | Description |
---|---|
201 - Created |
If the payload is valid, and a business has been created, a {
"kraken_business_id": 123,
"external_business_identifier": "external-123343243"
} |
400 - Bad Request |
If there are validation errors, a |
Payloads
Example payload
{
"import_supplier_code": "TENTACLE_ENERGY",
"external_business_identifier": "EXTERNAL-1234",
"business": {
"business_type": "EURL",
"company_name": "Test Company",
"siret": "60487647400494",
"details": [
{
"key": "siren",
"value": "604876474"
}
],
"business_contracts": [
{
"valid_from_date": "2023-01-01",
"signed_at_date": "2023-01-01",
"versions": [
{
"applicable_at_date": "2023-01-01",
"terms": [
{
"term_type": "CONTRACT_METADATA",
"metadata": {
"cee_formula_type": "standard"
}
},
{
"term_type": "PRODUCT_RATE_OVERRIDE_SCHEDULE",
"schedules": [
{
"effective_from": "2023-01-01",
"items": [
{
"price_per_unit": "0.2",
"rate_band": "CONSUMPTION_STANDARD",
"product_code": "ELEC-BUSINESS"
}
]
}
]
},
{
"term_type": "TERMINATION_FEE",
"amount": 100.0,
"supply_type": "ELECTRICITY",
"fee_type": "FLAT"
},
{
"term_type": "ISSUANCE_FREQUENCY",
"frequency": "MONTHLY",
"multiplier": 2,
"period_start_day": 1,
"period_start_month": 1
},
{
"term_type": "RATE_GROUP_ELIGIBILITY",
"schedules": [
{
"effective_period": {
"start_date": "2023-01-01"
},
"product_code": "ELEC-BUSINESS",
"rate_group_code": "BUSINESS_RATE_GROUP",
"is_eligible": true
}
]
}
]
}
],
"identifier": "ABC"
}
]
}
}