Skip to content

Episodes_ResetEpisodes

POST
/v1/accounts/{account}/datasets/{dataset}/episodes:reset
curl --request POST \
--url https://junction-api.qualiastudios.dev/v1/accounts/example/datasets/example/episodes:reset \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <X-API-Key>' \
--data '{ "parent": "example", "selection": { "names": { "names": [ "example" ] }, "filter": "example" } }'

Withdraws the standing ruling made in the parent’s scope, so the episode falls back to what stood before. Withdrawing a keep reopens the blocking issues that keep closed (RulingResult.reopened_issue_count).

account
required
string

The account id.

dataset
required
string

The dataset id.

Media type application/json

Request for Episodes.ResetEpisodes.

object
parent
required

Accounts/{account}/datasets/{dataset}: the scope whose ruling is withdrawn.

string
selection
required

Which episodes.

object
names

Episode names under the request’s parent.

object
names

Accounts/{account}/datasets/{dataset}/episodes/{episode}, at most 10000.

Array<string>
filter

A ListEpisodes filter over the parent (e.g. what the filter bar leaves).

string
Example generated
{
"parent": "example",
"selection": {
"names": {
"names": [
"example"
]
},
"filter": "example"
}
}

OK

Media type application/json

Response for Episodes.ResetEpisodes.

object
result

What happened.

object
changedCount

Episodes whose standing changed.

integer format: int32
unchangedCount

Episodes already standing that way.

integer format: int32
skippedCount

Episodes skipped: through a mixture, those not KEPT upstream (rejected or unreviewed in their upload or a mixture in between); anywhere, a Restore on an episode that is not a validation reject, and a Keep on a validation reject (RestoreEpisodes puts those back, with a reason).

integer format: int32
dismissedIssueCount

Open issues dismissed with a keep.

integer format: int32
lockedCount

Episodes the call would have changed but left as they were, because another person holds their edit lease. Not counted in skipped_count.

integer format: int32
locked

The first 100 of them, with their holders.

Array<object>

An episode a write left alone, or refused, because another person holds its edit lease (Episodes.AcquireEpisodeLease). Bulk responses list at most 100 of these beside a count of all of them.

object
episode

Accounts/{account}/datasets/{dataset}/episodes/{episode}, in the scope the write was made in.

string
holderName

The holder’s display name; empty when they have none.

string
reopenedIssueCount

Blocking issues a reset reopened: the ones the withdrawn keep had closed.

integer format: int32
Example generated
{
"result": {
"changedCount": 1,
"unchangedCount": 1,
"skippedCount": 1,
"dismissedIssueCount": 1,
"lockedCount": 1,
"locked": [
{
"episode": "example",
"holderName": "example"
}
],
"reopenedIssueCount": 1
}
}

Default error response

Media type application/json
One of:
API error

A refusal from the API itself.

object
code
required

The gRPC code name in upper case, e.g. NOT_FOUND.

string
message
required
string
retryable
required

Whether the same call may succeed if retried.

boolean
details
required

Empty, except when a dataset copy or move is refused: then one google.rpc.ErrorInfo with the refusal’s reason code, its domain and, in metadata, the datasets it names.

Array<object>
object
Example generated
{
"code": "example",
"message": "example",
"retryable": true,
"details": [
{}
]
}