Property and Facility Lifecycle

A lifecycle is the series of states into which a Facility and a Property change as it develops. By looking at the lifecycle, we can find out the current state. A Property or Facility can move between different states on the basis of workflows set in the application using it.

Property Lifecycle

A Property has two states:

  • Active - The Property is operational.
  • Inactive - The Property is decommissioned and is not operational.
19201920

You can transition a particular Property from one state to another using the PUT /properties/{propertyId}/transition endpoint. Make sure all the state-transition rules are satisfied. Specify the following parameters in the request body:

Member

Description

Remarks

toState

State to which you want to transition the Property.

Data type: string

reasonCode (optional)

Reason code for transition.

Data type: string

data

Any data generated or associated with respect to event transition.

Data type: object

propertyId (query parameter)

Participant ID of the Property for which you are requesting the state transition.

Data type: string

The following example request body shows how to change the state of a Property using the state transition endpoint:

{
  "toState": "active:available",
  "reasonCode": "R-123",
  "data": {}
}

Facility Lifecycle

A Facility has the following five lifecycle states:

  • Onboarding - The Facility is being retrofitted or set up for future operations.
  • Active - The Facility is operational and is ready to perform transactions.
  • Paused - The Facility is operational but can't do active transactions.
  • Deboarding - The Facility is non-operational.
  • Inactive - The Facility has been decommissioned.
19021902

To change the state of a Facility, use the PUT /facilities/{facilityId}/transition endpoint. Before calling the endpoint, ensure that the state-transition rules are satisfied. Specify the following parameters in the request body:

Member

Description

Remarks

toState

State to which you want to transition the Facility.

Data type: string

reasonCode (optional)

Reason code for transition.

Data type: string

data

Any data generated or associated with respect to event transition.

Data type: object

facilityId (Query parameter)

Participant ID of the Facility for which you are requesting the state transition.

Data type: string

The following example request body shows how to change the state of a Facility using the state transition endpoint:

{
  "toState": "active:available",
  "reasonCode": "R-112",
  "data": {}
}

State-transition Rules

There are certain rules that have to be followed while allowing for state transition:

  1. A Facility can only be onboarded against an active Property.
  2. A Property cannot be made inactive if there is a Facility with a state other than 'inactive' (onboarding, active, or deboarding) mapped to it.

Did this page help you?