GS2-Schedule Master Data Reference

Reference for the master data format and the models to be imported

Master Data Format

{
  "version": "2019-03-31",
  "events": [
    {
      "name": "[string]Event name",
      "metadata": "[string?]Metadata",
      "scheduleType": "[string enum]Schedule Type",
      "absoluteBegin": "[long?]Absolute Begin",
      "absoluteEnd": "[long?]Absolute End",
      "relativeTriggerName": "[string]Event start trigger name",
      "repeatSetting": {
        "repeatType": "[string]Repeat Type",
        "beginDayOfMonth": "[int]Begin Day of Month",
        "endDayOfMonth": "[int]End Day of Month",
        "beginDayOfWeek": "[string]Begin Day of Week",
        "endDayOfWeek": "[string]End Day of Week",
        "beginHour": "[int]Begin Hour",
        "endHour": "[int]End Hour",
        "anchorTimestamp": "[long]Anchor Timestamp",
        "activeDays": "[int]Active Days",
        "inactiveDays": "[int]Inactive Days"
      }
    }
  ]
}
TypeConditionRequiredDefaultValue LimitsDescription
versionstring
2019-03-31Format version of master data
eventsList<Event>~ 100 itemsEvent
Two types of event durations exist: absolute and relative.
Absolute periods are fixed periods, for example, from YYYY-MM-DD 00:00 (UTC) to YYYY-MM-DD 23:59 (UTC).
A relative period is an event period that varies from one game player to another, such as 24 hours from the time the trigger is activated.

In addition to the event duration, a repeat pattern can also be configured.
An event period can be set up so that only Monday from 10:00 to 11:00 is included in the event period.

Model

Event

Event

Two types of event durations exist: absolute and relative. Absolute periods are fixed periods, for example, from YYYY-MM-DD 00:00 (UTC) to YYYY-MM-DD 23:59 (UTC). A relative period is an event period that varies from one game player to another, such as 24 hours from the time the trigger is activated.

In addition to the event duration, a repeat pattern can also be configured. An event period can be set up so that only Monday from 10:00 to 11:00 is included in the event period.

TypeConditionRequiredDefaultValue LimitsDescription
eventIdstring
*
~ 1024 charsGS2-Schedule Event GRN
* Set automatically by the server
namestring
~ 128 charsEvent name
Event-specific name. Specified using alphanumeric characters, hyphens (-), underscores (_), and periods (.).
metadatastring~ 2048 charsMetadata
Arbitrary values can be set in the metadata.
Since they do not affect GS2’s behavior, they can be used to store information used in the game.
scheduleTypeString Enum
enum {
  “absolute”,
  “relative”
}
Schedule Type
Determines how the event period is defined.
“absolute” uses fixed start/end timestamps that are the same for all players.
“relative” uses a per-player trigger as the starting point, enabling personalized event periods (e.g., 24 hours from when each player first logs in).
DefinitionDescription
“absolute”Fixed period
“relative”Player-specific period
absoluteBeginlongAbsolute Begin
The fixed start time of the event period for absolute scheduling.
All players share the same start time. If not set for an absolute event, the event is considered to have started from the beginning of time.
Expressed as Unix time in milliseconds.
absoluteEndlongAbsolute End
The fixed end time of the event period for absolute scheduling.
All players share the same end time. If not set for an absolute event, the event is considered to have no end.
Expressed as Unix time in milliseconds.
relativeTriggerNamestring{scheduleType} == “relative”
✓*
~ 128 charsEvent start trigger name
Specify the name of the trigger that serves as the starting point for the event when setting an event period relative to each game player (relative).
Specified using alphanumeric characters, hyphens (-), underscores (_), and periods (.).
* Required if scheduleType is “relative”
repeatSettingRepeatSetting
Repeat Setting
Configuration for recurring time windows within the event period.
Allows narrowing the active period to specific hours, days of the week, days of the month, or custom active/inactive day cycles.
Set repeatType to “always” to keep the event active throughout the entire event period without any repeating pattern.

RepeatSetting

Repeat Setting

Configures a recurring time window within the overall event period. Supports five repeat types: “always” (entire event period), “daily” (specific hours each day), “weekly” (specific day-of-week range with hours), “monthly” (specific day-of-month range with hours), and “custom” (alternating active/inactive day cycles from an anchor date). When beginHour equals endHour for daily/weekly/monthly types, the end time is treated as the same hour on the following day (i.e., a full 24-hour window).

TypeConditionRequiredDefaultValue LimitsDescription
repeatTypeString Enum
enum {
  “always”,
  “daily”,
  “weekly”,
  “monthly”,
  “custom”
}
“always”Repeat Type
The type of repeat pattern to apply within the event period.
Determines which additional fields are required: daily/weekly/monthly require hour settings, weekly requires day-of-week, monthly requires day-of-month, and custom requires anchor timestamp and day counts.
Defaults to “always” if not specified.
DefinitionDescription
“always”Always during the entire event period
“daily”Every day during the event period from X:00 to X:00
“weekly”During the event period, every week from the start day to the end day, X:00 to X:00
“monthly”During the event period, every month from the start date to the end date, X:00 to X:00
“custom”Starting from the reference date, active for X days and inactive for Y days during the event period
beginDayOfMonthint{repeatType} == “monthly”
✓*
1 ~ 31Begin Day of Month
The day of the month when the repeat window starts (1-31).
If the specified value exceeds the number of days in a given month, it is treated as the last day of that month.
Only applicable when repeatType is “monthly”.
* Required if repeatType is “monthly”
endDayOfMonthint{repeatType} == “monthly”
✓*
1 ~ 31End Day of Month
The day of the month when the repeat window ends (1-31).
If the specified value exceeds the number of days in a given month, it is treated as the last day of that month.
Only applicable when repeatType is “monthly”.
* Required if repeatType is “monthly”
beginDayOfWeekString Enum
enum {
  “sunday”,
  “monday”,
  “tuesday”,
  “wednesday”,
  “thursday”,
  “friday”,
  “saturday”
}
{repeatType} == “weekly”
✓*
Begin Day of Week
The day of the week when the repeat window starts.
The window can span across week boundaries (e.g., Friday to Monday). Only applicable when repeatType is “weekly”.
DefinitionDescription
“sunday”Sunday
“monday”Monday
“tuesday”Tuesday
“wednesday”Wednesday
“thursday”Thursday
“friday”Friday
“saturday”Saturday
* Required if repeatType is “weekly”
endDayOfWeekString Enum
enum {
  “sunday”,
  “monday”,
  “tuesday”,
  “wednesday”,
  “thursday”,
  “friday”,
  “saturday”
}
{repeatType} == “weekly”
✓*
End Day of Week
The day of the week when the repeat window ends.
Combined with beginDayOfWeek to define the weekly active period. Only applicable when repeatType is “weekly”.
DefinitionDescription
“sunday”Sunday
“monday”Monday
“tuesday”Tuesday
“wednesday”Wednesday
“thursday”Thursday
“friday”Friday
“saturday”Saturday
* Required if repeatType is “weekly”
beginHourint{repeatType} in [“daily”, “weekly”, “monthly”]
✓*
0 ~ 23Begin Hour
The hour (UTC, 0-23) at which the repeat window starts each cycle.
Required for daily, weekly, and monthly repeat types. If beginHour equals endHour, the window spans a full 24 hours (ending at the same hour the next day).
* Required if repeatType is “daily”,“weekly”,“monthly”
endHourint{repeatType} in [“daily”, “weekly”, “monthly”]
✓*
0 ~ 24End Hour
The hour (UTC, 0-24) at which the repeat window ends each cycle.
A value of 24 represents midnight of the following day. Required for daily, weekly, and monthly repeat types.
* Required if repeatType is “daily”,“weekly”,“monthly”
anchorTimestamplong{repeatType} == “custom”
✓*
Anchor Timestamp
The reference date from which the custom active/inactive cycle begins.
The system calculates which phase (active or inactive) the current time falls into based on elapsed days from this anchor.
Only applicable when repeatType is “custom”. Expressed as Unix time in milliseconds.
* Required if repeatType is “custom”
activeDaysint{repeatType} == “custom”
✓*
1 ~ 2147483646Active Days
The number of consecutive days the event is active in each custom cycle.
After these active days, the event becomes inactive for the number of days specified by inactiveDays, then the cycle repeats.
Only applicable when repeatType is “custom”. Minimum 1 day.
* Required if repeatType is “custom”
inactiveDaysint{repeatType} == “custom”
✓*
0 ~ 2147483646Inactive Days
The number of consecutive days the event is inactive in each custom cycle.
Follows the active days period. Set to 0 for a continuously active event with no gaps.
Only applicable when repeatType is “custom”. Minimum 0 days.
* Required if repeatType is “custom”