Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
from ... import errors
from ...client import AuthenticatedClient, Client
from ...models.create_legacy_arm import CreateLegacyArm
from ...models.create_rollforward_arm import CreateRollforwardArm
from ...models.create_schedule_arm import CreateScheduleArm
from ...models.error_response import ErrorResponse
from ...models.operation_envelope_information_block_envelope import (
Expand All @@ -18,7 +19,7 @@
def _get_kwargs(
graph_id: str,
*,
body: CreateLegacyArm | CreateScheduleArm,
body: CreateLegacyArm | CreateRollforwardArm | CreateScheduleArm,
idempotency_key: None | str | Unset = UNSET,
) -> dict[str, Any]:
headers: dict[str, Any] = {}
Expand All @@ -34,6 +35,8 @@ def _get_kwargs(

if isinstance(body, CreateScheduleArm):
_kwargs["json"] = body.to_dict()
elif isinstance(body, CreateRollforwardArm):
_kwargs["json"] = body.to_dict()
else:
_kwargs["json"] = body.to_dict()

Expand Down Expand Up @@ -112,7 +115,7 @@ def sync_detailed(
graph_id: str,
*,
client: AuthenticatedClient,
body: CreateLegacyArm | CreateScheduleArm,
body: CreateLegacyArm | CreateRollforwardArm | CreateScheduleArm,
idempotency_key: None | str | Unset = UNSET,
) -> Response[ErrorResponse | OperationEnvelopeInformationBlockEnvelope]:
"""Create Information Block
Expand All @@ -127,8 +130,8 @@ def sync_detailed(
Args:
graph_id (str):
idempotency_key (None | str | Unset):
body (CreateLegacyArm | CreateScheduleArm): Create an Information Block. The body is a
discriminated union on
body (CreateLegacyArm | CreateRollforwardArm | CreateScheduleArm): Create an Information
Block. The body is a discriminated union on
`block_type`: pick the arm matching the block type you want to
create. The schedule arm carries a fully typed payload; statement
and metric arms accept an untyped payload but currently return HTTP
Expand Down Expand Up @@ -160,7 +163,7 @@ def sync(
graph_id: str,
*,
client: AuthenticatedClient,
body: CreateLegacyArm | CreateScheduleArm,
body: CreateLegacyArm | CreateRollforwardArm | CreateScheduleArm,
idempotency_key: None | str | Unset = UNSET,
) -> ErrorResponse | OperationEnvelopeInformationBlockEnvelope | None:
"""Create Information Block
Expand All @@ -175,8 +178,8 @@ def sync(
Args:
graph_id (str):
idempotency_key (None | str | Unset):
body (CreateLegacyArm | CreateScheduleArm): Create an Information Block. The body is a
discriminated union on
body (CreateLegacyArm | CreateRollforwardArm | CreateScheduleArm): Create an Information
Block. The body is a discriminated union on
`block_type`: pick the arm matching the block type you want to
create. The schedule arm carries a fully typed payload; statement
and metric arms accept an untyped payload but currently return HTTP
Expand All @@ -203,7 +206,7 @@ async def asyncio_detailed(
graph_id: str,
*,
client: AuthenticatedClient,
body: CreateLegacyArm | CreateScheduleArm,
body: CreateLegacyArm | CreateRollforwardArm | CreateScheduleArm,
idempotency_key: None | str | Unset = UNSET,
) -> Response[ErrorResponse | OperationEnvelopeInformationBlockEnvelope]:
"""Create Information Block
Expand All @@ -218,8 +221,8 @@ async def asyncio_detailed(
Args:
graph_id (str):
idempotency_key (None | str | Unset):
body (CreateLegacyArm | CreateScheduleArm): Create an Information Block. The body is a
discriminated union on
body (CreateLegacyArm | CreateRollforwardArm | CreateScheduleArm): Create an Information
Block. The body is a discriminated union on
`block_type`: pick the arm matching the block type you want to
create. The schedule arm carries a fully typed payload; statement
and metric arms accept an untyped payload but currently return HTTP
Expand Down Expand Up @@ -249,7 +252,7 @@ async def asyncio(
graph_id: str,
*,
client: AuthenticatedClient,
body: CreateLegacyArm | CreateScheduleArm,
body: CreateLegacyArm | CreateRollforwardArm | CreateScheduleArm,
idempotency_key: None | str | Unset = UNSET,
) -> ErrorResponse | OperationEnvelopeInformationBlockEnvelope | None:
"""Create Information Block
Expand All @@ -264,8 +267,8 @@ async def asyncio(
Args:
graph_id (str):
idempotency_key (None | str | Unset):
body (CreateLegacyArm | CreateScheduleArm): Create an Information Block. The body is a
discriminated union on
body (CreateLegacyArm | CreateRollforwardArm | CreateScheduleArm): Create an Information
Block. The body is a discriminated union on
`block_type`: pick the arm matching the block type you want to
create. The schedule arm carries a fully typed payload; statement
and metric arms accept an untyped payload but currently return HTTP
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
from ... import errors
from ...client import AuthenticatedClient, Client
from ...models.delete_legacy_arm import DeleteLegacyArm
from ...models.delete_rollforward_arm import DeleteRollforwardArm
from ...models.delete_schedule_arm import DeleteScheduleArm
from ...models.error_response import ErrorResponse
from ...models.operation_envelope_delete_information_block_response import (
Expand All @@ -18,7 +19,7 @@
def _get_kwargs(
graph_id: str,
*,
body: DeleteLegacyArm | DeleteScheduleArm,
body: DeleteLegacyArm | DeleteRollforwardArm | DeleteScheduleArm,
idempotency_key: None | str | Unset = UNSET,
) -> dict[str, Any]:
headers: dict[str, Any] = {}
Expand All @@ -34,6 +35,8 @@ def _get_kwargs(

if isinstance(body, DeleteScheduleArm):
_kwargs["json"] = body.to_dict()
elif isinstance(body, DeleteRollforwardArm):
_kwargs["json"] = body.to_dict()
else:
_kwargs["json"] = body.to_dict()

Expand Down Expand Up @@ -114,7 +117,7 @@ def sync_detailed(
graph_id: str,
*,
client: AuthenticatedClient,
body: DeleteLegacyArm | DeleteScheduleArm,
body: DeleteLegacyArm | DeleteRollforwardArm | DeleteScheduleArm,
idempotency_key: None | str | Unset = UNSET,
) -> Response[ErrorResponse | OperationEnvelopeDeleteInformationBlockResponse]:
"""Delete Information Block
Expand All @@ -129,8 +132,8 @@ def sync_detailed(
Args:
graph_id (str):
idempotency_key (None | str | Unset):
body (DeleteLegacyArm | DeleteScheduleArm): Delete an Information Block. The body is a
discriminated union on
body (DeleteLegacyArm | DeleteRollforwardArm | DeleteScheduleArm): Delete an Information
Block. The body is a discriminated union on
`block_type` mirroring `CreateInformationBlockRequest`. The schedule
arm carries a fully typed delete payload; statement and metric arms
return HTTP 501.
Expand Down Expand Up @@ -160,7 +163,7 @@ def sync(
graph_id: str,
*,
client: AuthenticatedClient,
body: DeleteLegacyArm | DeleteScheduleArm,
body: DeleteLegacyArm | DeleteRollforwardArm | DeleteScheduleArm,
idempotency_key: None | str | Unset = UNSET,
) -> ErrorResponse | OperationEnvelopeDeleteInformationBlockResponse | None:
"""Delete Information Block
Expand All @@ -175,8 +178,8 @@ def sync(
Args:
graph_id (str):
idempotency_key (None | str | Unset):
body (DeleteLegacyArm | DeleteScheduleArm): Delete an Information Block. The body is a
discriminated union on
body (DeleteLegacyArm | DeleteRollforwardArm | DeleteScheduleArm): Delete an Information
Block. The body is a discriminated union on
`block_type` mirroring `CreateInformationBlockRequest`. The schedule
arm carries a fully typed delete payload; statement and metric arms
return HTTP 501.
Expand All @@ -201,7 +204,7 @@ async def asyncio_detailed(
graph_id: str,
*,
client: AuthenticatedClient,
body: DeleteLegacyArm | DeleteScheduleArm,
body: DeleteLegacyArm | DeleteRollforwardArm | DeleteScheduleArm,
idempotency_key: None | str | Unset = UNSET,
) -> Response[ErrorResponse | OperationEnvelopeDeleteInformationBlockResponse]:
"""Delete Information Block
Expand All @@ -216,8 +219,8 @@ async def asyncio_detailed(
Args:
graph_id (str):
idempotency_key (None | str | Unset):
body (DeleteLegacyArm | DeleteScheduleArm): Delete an Information Block. The body is a
discriminated union on
body (DeleteLegacyArm | DeleteRollforwardArm | DeleteScheduleArm): Delete an Information
Block. The body is a discriminated union on
`block_type` mirroring `CreateInformationBlockRequest`. The schedule
arm carries a fully typed delete payload; statement and metric arms
return HTTP 501.
Expand Down Expand Up @@ -245,7 +248,7 @@ async def asyncio(
graph_id: str,
*,
client: AuthenticatedClient,
body: DeleteLegacyArm | DeleteScheduleArm,
body: DeleteLegacyArm | DeleteRollforwardArm | DeleteScheduleArm,
idempotency_key: None | str | Unset = UNSET,
) -> ErrorResponse | OperationEnvelopeDeleteInformationBlockResponse | None:
"""Delete Information Block
Expand All @@ -260,8 +263,8 @@ async def asyncio(
Args:
graph_id (str):
idempotency_key (None | str | Unset):
body (DeleteLegacyArm | DeleteScheduleArm): Delete an Information Block. The body is a
discriminated union on
body (DeleteLegacyArm | DeleteRollforwardArm | DeleteScheduleArm): Delete an Information
Block. The body is a discriminated union on
`block_type` mirroring `CreateInformationBlockRequest`. The schedule
arm carries a fully typed delete payload; statement and metric arms
return HTTP 501.
Expand Down
Loading
Loading