scenario

Create a scenario

post/v1/org/{orgId}/scenario

Request

  • Base URL: https://localhost
  • URL: https://localhost/v1/org/{orgId}/scenario
  • Auth: none declared

Path parameters

orgIdstring required

Org identifier (either id or slug)

Query parameters

silentboolean

Suppress notification emails

skipChangeCreationboolean

Skip over change creation for PROMOTION scenarios

Request body

namestring required

scenario name

descriptionstring

scenario description

startDatestring date

date that this scenario diverges from primary

status'OPEN' | 'INACTIVE' | 'MERGED' | 'DRAFT' | 'ARCHIVED'

status of scenario

type'GENERAL' | 'COMP' | 'PROMOTION' | 'TERMINATE' | 'CREATE_JOB' | 'UPDATE_JOB' | 'BUDGET' | 'BACKFILL'

Type of scenario: GENERAL (custom, for any changes; the default), BUDGET (plan against budget from a startDate), PROMOTION (promotions and raises for the jobs matching query), or a Simple workflow for one change to one job or person: CREATE_JOB, UPDATE_JOB, TERMINATE, BACKFILL. COMP scenarios can't be created this way. To the user, call them Custom, Budget, Promotion, Create job, Update job, Terminate & backfill and Backfill, never by these codes.

startDateFixed'FIXED' | 'TODAY' required

FIXED keeps startDate as set; TODAY moves the start date to the current date as time passes. BUDGET scenarios use FIXED.

querystring

PROMOTION scenarios only: a CQL filter for the jobs being planned for, e.g. department:Engineering. Each matching job is added to the scenario; a blank filter adds every job, so ask the user for one.

validJobIdSetstring[]

This scenario changes are restricted to the following jobIds

entityIdstring

The entity this scenario is associated with

entityType'COMP_REVIEW' | 'ASSESSMENT'

The type of entity associated with this scenario

Example request

{
  "name": "Q4 Conservative Plan",
  "description": "Q4 Conservative Plan",
  "startDate": "2017-01-15",
  "shareAccess": [
    {
      "userId": "5887a7718f138b6a2a0041a7",
      "groupId": "5887a7718f138b6a2a0041a7",
      "fields": "name,image,title"
    }
  ],
  "validJobIdSet": [
    "588f7ee98f138b19220041a7"
  ],
  "entityId": "588f7ee98f138b19220041a7",
  "sharedViewConfig": [
    {
      "updateId": "588f7ee98f138b19220041a7"
    }
  ]
}

Response

scenario created

idstring required

globally unique id

orgIdstring required

parent organization id

namestring required

scenario name

descriptionstring

scenario description

startDatestring date required

date that this scenario diverges from primary

status'OPEN' | 'INACTIVE' | 'MERGED' | 'DRAFT' | 'ARCHIVED' required

status of scenario

changeCountinteger

number of changes contained in scenario

changeCountsobject

number of changes of each type contained in scenario

maxChangeEffectiveDatestring date

the latest effective date among all changes in the scenario (max of change.date); null until the scenario has been recalculated

createIdstring required

created by user id

createBehalfIdstring

created on behalf of user id

createAtstring required

created timestamp

updateIdstring required

last updated by user id

updateBehalfIdstring

last updated on behalf of user id

updateAtstring required

last updated timestamp

deleteIdstring

deleted by user id

deleteBehalfIdstring

deleted on behalf of user id

deleteAtstring

deleted timestamp

mergeIdstring

merged by user id

mergeAtstring

merged timestamp

calcStartAtstring

most recent summary calculation started at timestamp

calcEndAtstring

most recent summary calculation ended at timestamp

changeAtstring

timestamp of most recent changes made to scenario

changeIdstring

user who made the most recent change to scenario

type'GENERAL' | 'COMP' | 'PROMOTION' | 'TERMINATE' | 'CREATE_JOB' | 'UPDATE_JOB' | 'BUDGET' | 'BACKFILL'

Type of scenario: GENERAL (custom, for any changes; the default), BUDGET (plan against budget from a startDate), PROMOTION (promotions and raises for the jobs matching query), or a Simple workflow for one change to one job or person: CREATE_JOB, UPDATE_JOB, TERMINATE, BACKFILL. COMP scenarios can't be created this way. To the user, call them Custom, Budget, Promotion, Create job, Update job, Terminate & backfill and Backfill, never by these codes.

startDateFixed'FIXED' | 'TODAY' required

FIXED keeps startDate as set; TODAY moves the start date to the current date as time passes. BUDGET scenarios use FIXED.

querystring

PROMOTION scenarios only: a CQL filter for the jobs being planned for, e.g. department:Engineering. Each matching job is added to the scenario; a blank filter adds every job, so ask the user for one.

validJobIdSetstring[]

This scenario changes are restricted to the following jobIds

approvalRequestIdstring

Approval request id, if the scenario has been submitted for approval

entityIdstring

The entity this scenario is associated with

entityType'COMP_REVIEW' | 'ASSESSMENT'

The type of entity associated with this scenario

Example response

{
  "id": "588f7ee98f138b19220041a7",
  "orgId": "588f7ee98f138b19220041a7",
  "name": "Q4 Conservative Plan",
  "description": "Q4 Conservative Plan",
  "startDate": "2017-01-15",
  "shareAccess": [
    {
      "userId": "5887a7718f138b6a2a0041a7",
      "groupId": "5887a7718f138b6a2a0041a7",
      "fields": "name,image,title"
    }
  ],
  "maxChangeEffectiveDate": "2027-04-15",
  "createId": "588f7ee98f138b19220041a7",
  "createBehalfId": "588f7ee98f138b19220041a7",
  "createAttribution": {
    "principalUserId": "588f7ee98f138b19220041a7",
    "agentUserIds": [
      "588f7ee98f138b19220041a7"
    ],
    "eventId": "588f7ee98f138b19220041a7",
    "aiChatId": "588f7ee98f138b19220041a7"
  },
  "createAt": "2017-01-24T13:57:52Z",
  "updateId": "588f7ee98f138b19220041a7",
  "updateBehalfId": "588f7ee98f138b19220041a7",
  "updateAttribution": {
    "principalUserId": "588f7ee98f138b19220041a7",
    "agentUserIds": [
      "588f7ee98f138b19220041a7"
    ],
    "eventId": "588f7ee98f138b19220041a7",
    "aiChatId": "588f7ee98f138b19220041a7"
  },
  "updateAt": "2017-01-24T13:57:52Z",
  "deleteId": "588f7ee98f138b19220041a7",
  "deleteBehalfId": "588f7ee98f138b19220041a7",
  "deleteAttribution": {
    "principalUserId": "588f7ee98f138b19220041a7",
    "agentUserIds": [
      "588f7ee98f138b19220041a7"
    ],
    "eventId": "588f7ee98f138b19220041a7",
    "aiChatId": "588f7ee98f138b19220041a7"
  },
  "deleteAt": "2017-01-24T13:57:52Z",
  "mergeId": "588f7ee98f138b19220041a7",
  "mergeAt": "2017-01-24T13:57:52Z",
  "calcStartAt": "2017-01-24T13:57:52Z",
  "calcEndAt": "2017-01-24T13:57:52Z",
  "changeAt": "2017-01-24T13:57:52Z",
  "changeId": "2017-01-24T13:57:52Z",
  "validJobIdSet": [
    "588f7ee98f138b19220041a7"
  ],
  "approvalRequestId": "588f7ee98f138b19220041a7",
  "entityId": "588f7ee98f138b19220041a7",
  "sharedViewConfig": [
    {
      "updateId": "588f7ee98f138b19220041a7"
    }
  ]
}

Changes

No recorded changes to this operation across all 22 revisions of this API.