Skip to content

Commit

Permalink
Task changes (#60)
Browse files Browse the repository at this point in the history
Added new tasks, translation update. Return only 1st pending task from
the group (for groupped tasks), badges/levels are returned in pending
list only when badge/level was achieved. Do not complete any task
automatically for v2 tasks api, only by request. dryRun pseudo completed
task request.
  • Loading branch information
ice-myles authored Oct 3, 2024
1 parent 027affa commit 1f4f02d
Show file tree
Hide file tree
Showing 356 changed files with 1,533 additions and 2,195 deletions.
321 changes: 238 additions & 83 deletions application.yaml

Large diffs are not rendered by default.

73 changes: 58 additions & 15 deletions cmd/santa-sleigh/api/docs.go
Original file line number Diff line number Diff line change
Expand Up @@ -377,14 +377,16 @@ const docTemplate = `{
"claim_username",
"start_mining",
"upload_profile_picture",
"follow_us_on_twitter",
"join_twitter",
"join_telegram",
"invite_friends",
"join_youtube",
"watch_video_with_code_confirmation_1",
"invite_friends_5",
"invite_friends_10",
"invite_friends_25",
"invite_friends_50",
"invite_friends_100",
"invite_friends_200",
"join_youtube",
"watch_video_with_code_confirmation_1",
"claim_badge_l1",
"claim_badge_l2",
"claim_badge_l3",
Expand Down Expand Up @@ -434,7 +436,14 @@ const docTemplate = `{
"claim_level_21",
"mining_streak_7",
"mining_streak_14",
"mining_streak_30"
"mining_streak_30",
"join_reddit_ion",
"join_instagram_ion",
"join_twitter_ion",
"join_telegram_ion",
"signup_callfluent",
"signup_sauces",
"signup_sealsend"
],
"type": "string",
"description": "the type of the task",
Expand All @@ -448,6 +457,12 @@ const docTemplate = `{
"name": "userId",
"in": "path",
"required": true
},
{
"type": "string",
"description": "language of translations for task description",
"name": "language",
"in": "query"
}
],
"responses": {
Expand Down Expand Up @@ -531,10 +546,12 @@ const docTemplate = `{
"invite_friends",
"invite_friends_5",
"invite_friends_10",
"invite_friends_25",
"invite_friends_50",
"invite_friends_100",
"invite_friends_200",
"join_youtube",
"watch_video_with_code_confirmation_1",
"invite_friends_5",
"invite_friends_10",
"claim_badge_l1",
"claim_badge_l2",
"claim_badge_l3",
Expand Down Expand Up @@ -584,7 +601,14 @@ const docTemplate = `{
"claim_level_21",
"mining_streak_7",
"mining_streak_14",
"mining_streak_30"
"mining_streak_30",
"join_reddit_ion",
"join_instagram_ion",
"join_twitter_ion",
"join_telegram_ion",
"signup_callfluent",
"signup_sauces",
"signup_sealsend"
],
"type": "string",
"description": "the type of the task",
Expand All @@ -599,13 +623,6 @@ const docTemplate = `{
"in": "path",
"required": true
},
{
"type": "string",
"description": "language to get tasks translation",
"name": "language",
"in": "path",
"required": true
},
{
"description": "Request params. Set it only if task completion requires additional data.",
"name": "request",
Expand Down Expand Up @@ -880,10 +897,23 @@ const docTemplate = `{
"join_twitter",
"join_telegram",
"invite_friends",
"join_twitter",
"join_telegram",
"join_reddit_ion",
"join_instagram_ion",
"join_twitter_ion",
"join_telegram_ion",
"join_youtube",
"watch_video_with_code_confirmation_1",
"invite_friends_5",
"invite_friends_10",
"invite_friends_25",
"invite_friends_50",
"invite_friends_100",
"invite_friends_200",
"signup_callfluent",
"signup_sauces",
"signup_sealsend",
"claim_badge_l1",
"claim_badge_l2",
"claim_badge_l3",
Expand Down Expand Up @@ -943,10 +973,23 @@ const docTemplate = `{
"JoinTwitterType",
"JoinTelegramType",
"InviteFriendsType",
"JoinTwitterUsType",
"JoinTelegramUsType",
"JoinRedditIONType",
"JoinInstagramIONType",
"JoinTwitterIONType",
"JoinTelegramIONType",
"JoinYoutubeType",
"WatchVideoWithCodeConfirmation1Type",
"InviteFriends5Type",
"InviteFriends10Type",
"InviteFriends25Type",
"InviteFriends50Type",
"InviteFriends100Type",
"InviteFriends200Type",
"SignUpCallfluentType",
"SignUpSaucesType",
"SignUpSealsendType",
"ClaimLevelBadge1Type",
"ClaimLevelBadge2Type",
"ClaimLevelBadge3Type",
Expand Down
73 changes: 58 additions & 15 deletions cmd/santa-sleigh/api/swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -370,14 +370,16 @@
"claim_username",
"start_mining",
"upload_profile_picture",
"follow_us_on_twitter",
"join_twitter",
"join_telegram",
"invite_friends",
"join_youtube",
"watch_video_with_code_confirmation_1",
"invite_friends_5",
"invite_friends_10",
"invite_friends_25",
"invite_friends_50",
"invite_friends_100",
"invite_friends_200",
"join_youtube",
"watch_video_with_code_confirmation_1",
"claim_badge_l1",
"claim_badge_l2",
"claim_badge_l3",
Expand Down Expand Up @@ -427,7 +429,14 @@
"claim_level_21",
"mining_streak_7",
"mining_streak_14",
"mining_streak_30"
"mining_streak_30",
"join_reddit_ion",
"join_instagram_ion",
"join_twitter_ion",
"join_telegram_ion",
"signup_callfluent",
"signup_sauces",
"signup_sealsend"
],
"type": "string",
"description": "the type of the task",
Expand All @@ -441,6 +450,12 @@
"name": "userId",
"in": "path",
"required": true
},
{
"type": "string",
"description": "language of translations for task description",
"name": "language",
"in": "query"
}
],
"responses": {
Expand Down Expand Up @@ -524,10 +539,12 @@
"invite_friends",
"invite_friends_5",
"invite_friends_10",
"invite_friends_25",
"invite_friends_50",
"invite_friends_100",
"invite_friends_200",
"join_youtube",
"watch_video_with_code_confirmation_1",
"invite_friends_5",
"invite_friends_10",
"claim_badge_l1",
"claim_badge_l2",
"claim_badge_l3",
Expand Down Expand Up @@ -577,7 +594,14 @@
"claim_level_21",
"mining_streak_7",
"mining_streak_14",
"mining_streak_30"
"mining_streak_30",
"join_reddit_ion",
"join_instagram_ion",
"join_twitter_ion",
"join_telegram_ion",
"signup_callfluent",
"signup_sauces",
"signup_sealsend"
],
"type": "string",
"description": "the type of the task",
Expand All @@ -592,13 +616,6 @@
"in": "path",
"required": true
},
{
"type": "string",
"description": "language to get tasks translation",
"name": "language",
"in": "path",
"required": true
},
{
"description": "Request params. Set it only if task completion requires additional data.",
"name": "request",
Expand Down Expand Up @@ -873,10 +890,23 @@
"join_twitter",
"join_telegram",
"invite_friends",
"join_twitter",
"join_telegram",
"join_reddit_ion",
"join_instagram_ion",
"join_twitter_ion",
"join_telegram_ion",
"join_youtube",
"watch_video_with_code_confirmation_1",
"invite_friends_5",
"invite_friends_10",
"invite_friends_25",
"invite_friends_50",
"invite_friends_100",
"invite_friends_200",
"signup_callfluent",
"signup_sauces",
"signup_sealsend",
"claim_badge_l1",
"claim_badge_l2",
"claim_badge_l3",
Expand Down Expand Up @@ -936,10 +966,23 @@
"JoinTwitterType",
"JoinTelegramType",
"InviteFriendsType",
"JoinTwitterUsType",
"JoinTelegramUsType",
"JoinRedditIONType",
"JoinInstagramIONType",
"JoinTwitterIONType",
"JoinTelegramIONType",
"JoinYoutubeType",
"WatchVideoWithCodeConfirmation1Type",
"InviteFriends5Type",
"InviteFriends10Type",
"InviteFriends25Type",
"InviteFriends50Type",
"InviteFriends100Type",
"InviteFriends200Type",
"SignUpCallfluentType",
"SignUpSaucesType",
"SignUpSealsendType",
"ClaimLevelBadge1Type",
"ClaimLevelBadge2Type",
"ClaimLevelBadge3Type",
Expand Down
Loading

0 comments on commit 1f4f02d

Please sign in to comment.