Directive Upsert Many Ep
POST/v1/directive/upsert_many
Create Curve Groups
Used to create Curve Groups, which can be thought of as a contract or group of definitions used to generate directives.
Request
source_id: str | None = None
Not implemented.
name: str
Name of the group, typically set as a contract name.
keys: array
Array of key definitions mapping loaded volume to this group. For product, supplier, and terminal, either the name or both the source_id and source_system need to be provided.
Show Child Attributes
contract: str | None = None
Name of the contract for this key, typically the same for all keys in a group.
price_type: str
One of "rack", "contract", "index", "inventory", "spot".
product_source_id: str | None = None
The identifier of the product in an external system.
product_source_system: str | None = None
The name of the system where the product_source_id resides.
product: str | None = None
The name of the product.
supplier_source_id: str | None = None
The identifier of the supplier in an external system.
supplier_source_system: str | None = None
The name of the system where the supplier_source_id resides.
supplier: str | None = None
The name of the supplier.
terminal_source_id: str | None = None
The identifier of the terminal in an external system.
terminal_source_system: str | None = None
The name of the system where the terminal_source_id resides.
terminal: str | None = None
The name of the terminal.
as_of: datetime
Only the date part is used.
min: float | None = None
The minimum directive volume.
max: float | None = None
The maximum directive volume.
volume_distributions: array | None = []
Array for allocating directive volume across markets.
Show Child Attributes
market: str
Name of the market to allocate volume towards.
percent: float
Decimal percentage of the volume allocated to the market (e.g., 23% = 0.23).
contract_volumes: array | None = []
Array representing monthly allocations across a contract, used for calculating allocations and contract pace.
Show Child Attributes
applicable_date: date
Month and year determine the volume applicable to the current month.
volume: float
The monthly allocation volume, used for weekly and daily allocations.
daily_percent: float | None = None
Decimal percentage multiplied by the daily allocation for the daily start allocation.
weekly_percent: float | None = None
Decimal percentage multiplied by the weekly allocation for the weekly start allocation.
monthly_percent: float | None = None
Decimal percentage multiplied by the monthly allocation for the monthly start allocation.
week_start_day: DayOfWeek | None = None
Indicates the start day of the week.
Show Deprecated
start_hour: int | None = None
Deprecated.
Response
success: bool
Whether all the requests succeeded or not.
good: array
An array of the requests that succeeded.
bad: array
An array of the requests that failed.
Responses
- 200
- 422
Successful Response
Validation Error
- application/json
- Example (from schema)
{
"detail": [
{
"loc": [
"string",
0
],
"msg": "string",
"type": "string"
}
]
}