17 February 2020
ExtensibilityGraphQL
States can now be modified using the GraphQL API.
- 
[GraphQL API] Added the following types to the GraphQL schema:
StateDraft,StateUpdateAction,AddStateRoles,ChangeStateInitial,ChangeStateKey,ChangeStateType,SetStateDescription,SetStateName,SetStateRoles,SetStateTransitions,RemoveStateRoles. - 
[GraphQL API] Changed the
Mutationtype:- Added the 
createStatefield to theMutationtype. - Added the 
updateStatefield to theMutationtype. - Added the 
deleteStatefield to theMutationtype. 
 - Added the 
 
Introduced the following changes to the GraphQL schema (in SDL format):
extend type Mutation {
  createState(draft: StateDraft!): State
  updateState(version: Long!, actions: [StateUpdateAction!]!,
    "Queries with specified ID"
    id: String,
    "Queries with specified key"
    key: String): State
  deleteState(version: Long!,
    "Queries with specified ID"
    id: String,
    "Queries with specified key"
    key: String): State
}
input StateDraft {
  key: String!
  type: StateType!
  name: [LocalizedStringItemInputType!]
  description: [LocalizedStringItemInputType!]
  initial: Boolean
  roles: [StateRole!]
  transitions: [ReferenceInput!]
}
input StateUpdateAction {
  addRoles: AddStateRoles
  changeInitial: ChangeStateInitial
  changeKey: ChangeStateKey
  changeType: ChangeStateType
  removeRoles: RemoveStateRoles
  setDescription: SetStateDescription
  setName: SetStateName
  setRoles: SetStateRoles
  setTransitions: SetStateTransitions
}
input AddStateRoles {
  roles: [StateRole!]!
}
input ChangeStateInitial {
  initial: Boolean!
}
input ChangeStateKey {
  key: String!
}
input ChangeStateType {
  type: StateType!
}
input SetStateDescription {
  description: [LocalizedStringItemInputType!]
}
input SetStateName {
  name: [LocalizedStringItemInputType!]
}
input SetStateRoles {
  roles: [StateRole!]!
}
input SetStateTransitions {
  transitions: [ResourceIdentifierInput!]
}
input RemoveStateRoles {
  roles: [StateRole!]!
}