> ## Documentation Index
> Fetch the complete documentation index at: https://docs.canton.network/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> If you are building a Canton Network application, start from https://docs.canton.network/appdev/quickstart.md. To run only a local network for your own Daml code, without building the QuickStart demo, see https://docs.canton.network/sdks-tools/development-tools/localnet.md.

# /v2/state/active-contracts

> Returns a stream of the snapshot of the active contracts and incomplete (un)assignments at a ledger offset. Once the stream of GetActiveContractsResponses completes, the client SHOULD begin streaming updates from the update service, starting at the GetActiveContractsRequest.active_at_offset specified in this request. Clients SHOULD NOT assume that the set of active contracts they receive reflects the state at the ledger end. If the given offset is different than the ledger end, and there are (un)assignments in-flight at the given offset, the snapshot may fail with "FAILED_PRECONDITION/PARTICIPANT_PRUNED_DATA_ACCESSED". Note that it is ok to request acs snapshots for party migration with offsets other than ledger end, because party migration is not concerned with incomplete (un)assignments.

[Back to overview](https://docs.canton.network/reference/json-api-asyncapi-reference/index.md)

AsyncAPI Channel

# /v2/state/active-contracts

Returns a stream of the snapshot of the active contracts and incomplete (un)assignments at a ledger offset. Once the stream of GetActiveContractsResponses completes, the client...

WebSocket

[Updated 3.7](#history-updated-3-7)

Channel
/v2/state/active-contracts

Actions
publish, subscribe

## Actions

Returns a stream of the snapshot of the active contracts and incomplete (un)assignments at a ledger offset.
Once the stream of GetActiveContractsResponses completes,
the client SHOULD begin streaming updates from the update service,
starting at the GetActiveContractsRequest.active\_at\_offset specified in this request.
Clients SHOULD NOT assume that the set of active contracts they receive reflects the state at the ledger end.
If the given offset is different than the ledger end, and there are (un)assignments in-flight at the given offset,
the snapshot may fail with "FAILED\_PRECONDITION/PARTICIPANT\_PRUNED\_DATA\_ACCESSED".
Note that it is ok to request acs snapshots for party migration with offsets other than ledger end, because party
migration is not concerned with incomplete (un)assignments.

[publish /v2/state/active-contracts](https://docs.canton.network/reference/json-api-asyncapi-reference/operations/v2-state-active-contracts/publish.md)

WebSocket

Updated 3.7

Returns a stream of the snapshot of the active contracts and incomplete (un)assignments at a ledger offset. Once the stream of GetActiveContractsResponses completes, t...

Operation ID
sendV2StateActive-contracts

Method
\-

Payload
object

[subscribe /v2/state/active-contracts](https://docs.canton.network/reference/json-api-asyncapi-reference/operations/v2-state-active-contracts/subscribe.md)

WebSocket

Updated 3.7

Returns a stream of the snapshot of the active contracts and incomplete (un)assignments at a ledger offset. Once the stream of GetActiveContractsResponses completes, t...

Operation ID
onV2StateActive-contracts

Method
\-

Payload
oneOf

## History

Updated
`3.7`

publish: channel description updated; publish required fields added: `eventFormat`

subscribe: channel description updated

Updated
`3.5`

publish: channel description updated; publish description updated; publish required fields removed: `eventFormat`

subscribe: channel description updated; subscribe description updated
