# Interface: TMissionOrBadge

TMissionOrBadge describes the information of mission or badge defined in the system

## Properties

### id

> **id**: `number`

ID of the mission or badge

***

### type

> **type**: `"mission"` \| `"badge"`

Type of entity. Can be 'mission' or 'badge'

***

### name

> **name**: `string`

Name of the mission or badge, translated to the user language

***

### sub\_header

> **sub\_header**: `string`

Sub-header of the mission, translated to the user language

***

### description

> **description**: `string`

Description of the mission or badge, translated to the user language

***

### reward

> **reward**: `string`

Description of the mission reward if defined

***

### image

> **image**: `string`

URL of the image of the mission or badge, 256x256px

***

### is\_completed

> **is\_completed**: `boolean`

Indicator if the mission is completed or badge is granted. Stays `false` for
Recurring-upon-completion missions even after cycles complete — use `completion_count`
to detect completed cycles (see `getMissions` bucketing).

***

### is\_locked

> **is\_locked**: `boolean`

Indicator if the mission is locked. Means that it's visible to the user, but he cannot progress in it until it's unlocked.
Mission may optionally contain the explanation of what should be done to unlock it in the unlock_mission_description property

***

### unlock\_mission\_description

> **unlock\_mission\_description**: `string`

Optional explaination of what should be done to unlock the mission

***

### is\_requires\_optin

> **is\_requires\_optin**: `boolean`

Indicator if the mission requires opt-in. Means that user should explicitly opt-in to the mission in order to start progressing in it

***

### is\_opted\_in

> **is\_opted\_in**: `boolean`

Indicator if the user opted-in to the mission

***

### time\_limit\_ms

> **time\_limit\_ms**: `number`

The amount of time in milliseconds that user has to complete the mission

***

### active\_from\_ts

> **active\_from\_ts**: `number`

Holds time from which mission will become available, for the missions that are targeted to be available from specific date/time

***

### active\_till\_ts

> **active\_till\_ts**: `number`

Holds time till mission will become unavailable, for the missions that are targeted to be available from specific date/time

***

### dt\_start

> **dt\_start**: `number`

The date when the mission was started, relevant for the time limited missions, also indicating opt-it date for mission that requires opt-in and unlock date for Locked mission.

***

### progress

> **progress**: `number`

The progress of the mission in percents calculated as the aggregated relative percentage of all tasks

***

### cta\_action

> **cta\_action**: `string`

The action that should be performed when user clicks on the mission or badge
Can be URL or deep link, e.g. 'dp:deposit'. The most safe to execute CTA is to pass it to _smartico.dp(cta_action);
The 'dp' function will handle the CTA and will execute it in the most safe way

***

### cta\_text

> **cta\_text**: `string`

The text of the CTA button, e.g. 'Make a deposit'

***

### custom\_section\_id

> **custom\_section\_id**: `number`

The ID of the custom section where the mission or badge is assigned.
Resolve to section metadata via `_smartico.api.getCustomSections()`.

***

### only\_in\_custom\_section

> **only\_in\_custom\_section**: `boolean`

The indicator if the mission or badge is visible only in the custom section and should be hidden from the main overview of missions/badges

***

### custom\_data

> **custom\_data**: `any`

The custom data of the mission or badge defined by operator. Can be a JSON object, string or number

***

### tasks

> **tasks**: [`TMissionOrBadgeTask`](TMissionOrBadgeTask.md)[]

The list of tasks of the mission or badge

***

### related\_games?

> `optional` **related\_games?**: [`AchRelatedGame`](AchRelatedGame-1.md)[]

List of casino games (or other types of entities) related to the mission or badge

***

### category\_ids

> **category\_ids**: `number`[]

The list of IDs of the categories where the badge item is assigned, information about categories can be retrieved with getAchCategories method

***

### hint\_text?

> `optional` **hint\_text?**: `string`

The T&C text for the missions

***

### position?

> `optional` **position?**: `number`

Priority (or position) of the mission in the UI. Low value indicates higher position in the UI

***

### ribbon?

> `optional` **ribbon?**: `string`

The ribbon of the mission/badge item. Can be 'sale', 'hot', 'new', 'vip' or URL to the image in case of custom ribbon, 250x300px

***

### ach\_completed\_id?

> `optional` **ach\_completed\_id?**: `number`

Stable identifier of this specific mission completion. Undefined for
badges and for missions that have not yet completed.

***

### requires\_prize\_claim?

> `optional` **requires\_prize\_claim?**: `boolean`

Flag from achievement if the mission prize will be given only after user claims it

***

### prize\_claimed\_date\_ts?

> `optional` **prize\_claimed\_date\_ts?**: `number`

The date/timestamp indicating when the prize was claimed by the user

***

### complete\_date?

> `optional` **complete\_date?**: `string`

Date-time the mission/badge was completed, as a `"dd/MM/yyyy HH:mm:ss"` string
(server local — NOT ISO-8601, so `new Date(complete_date)` will not parse it).
Prefer the epoch-ms `complete_date_ts` for date math.

***

### complete\_date\_ts?

> `optional` **complete\_date\_ts?**: `number`

Time of mission/badge being completed, this property shows the epoch time in UTC

***

### completed\_today?

> `optional` **completed\_today?**: `boolean`

Flag for mission/badge indicating that mission/badge completed today

***

### completed\_this\_week?

> `optional` **completed\_this\_week?**: `boolean`

Flag for mission/badge indicating that mission/badge completed this week

***

### completed\_this\_month?

> `optional` **completed\_this\_month?**: `boolean`

Flag for mission/badge indicating that mission/badge completed this month

***

### custom\_section\_type\_id?

> `optional` **custom\_section\_type\_id?**: `number`

ID of specific Custom Section type

***

### max\_completion\_count?

> `optional` **max\_completion\_count?**: `number`

Max number of times the user can complete a mission in case if mission type is Recurring upon completion. NULL equals infinite (still recurring — not "no cap disables recurring").

***

### completion\_count?

> `optional` **completion\_count?**: `number`

Current completion count for Recurring-upon-completion missions. Non-null ONLY for that mission type, so its presence identifies one; `> 0` means at least one cycle completed.

***

### next\_recurrence\_date\_ts?

> `optional` **next\_recurrence\_date\_ts?**: `number`

The date/timestamp for recurring missions, which indicating the time remaining until the next recurrence of the mission.
Note that if a mission has an "Active till" date defined, this field is not relevant after that date.

***

### availability\_status?

> `optional` **availability\_status?**: [`AchievementAvailabilityStatus`](../enumerations/AchievementAvailabilityStatus.md)

Timer/window state derived from the mission's time limits (which countdown to show / whether the window elapsed). NOT a tab-bucketing signal — it ignores `completion_count`, so bucket sections from the raw fields instead (see `getMissions`).

***

### claim\_button\_title?

> `optional` **claim\_button\_title?**: `string`

Title for the claim reward button

***

### claim\_button\_action?

> `optional` **claim\_button\_action?**: `string`

Action for the claim reward button

***

### prize\_claim\_expiration\_date?

> `optional` **prize\_claim\_expiration\_date?**: `number`

The date/timestamp indicating when the mission claim will expire

***

### prize\_claim\_period\_type\_id?

> `optional` **prize\_claim\_period\_type\_id?**: [`AchievementClaimPeriodTypeId`](../enumerations/AchievementClaimPeriodTypeId.md)

The type of the prize claim period (Relative or Exact time and date)

***

### badgeTimeLimitState?

> `optional` **badgeTimeLimitState?**: [`BadgesTimeLimitStates`](../enumerations/BadgesTimeLimitStates.md)

Badge time limit state for badges with time restrictions

***

### hide\_locked\_mission?

> `optional` **hide\_locked\_mission?**: `boolean`

Flag from achievement if the mission should be hidden when it is locked, until it's unlocked
