{"swagger": "2.0", "info": {"title": "WeFitter API", "description": "This is the WeFitter API", "termsOfService": "https://www.wefitter.com/privacy/", "contact": {"email": "hello@wefitter.com"}, "license": {"name": "BSD License"}, "version": "v1"}, "host": "api.wefitter.com", "schemes": ["https"], "basePath": "/api/v1", "consumes": ["application/json"], "produces": ["application/json"], "securityDefinitions": {"Basic": {"type": "basic", "description": "Basic Authentication is used to create administrator bearer tokens.\n\nOnce a bearer token has been made, remove this auth. ('logout' in Swagger')"}, "BearerProfile": {"type": "apiKey", "name": "Authorization", "in": "header", "description": "Bearer authentication for logged-in profiles.\n\nWhen using the GUI, please don't forget to prefix your bearer tokens with the text 'bearer', followed by a space."}, "BearerAdmin": {"type": "apiKey", "name": "Authorization", "in": "header", "description": "Bearer authentication for administrators.\n\nWhen using the GUI, please don't forget to prefix your bearer tokens with the text 'bearer', followed by a space."}}, "security": [{"BearerProfile": []}], "paths": {"/app/totals/": {"get": {"operationId": "app_totals_list", "summary": "Totals", "description": "Total values for calories, distance, steps, points and activity duration over all profiles in the app.", "parameters": [], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/AppTotals"}}}}, "tags": ["app"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "parameters": []}, "/challenge/": {"get": {"operationId": "challenge_list", "summary": "List Challenges", "description": "Lists all available challenges", "parameters": [{"name": "limit", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "offset", "in": "query", "description": "The initial index from which to return the results.", "required": false, "type": "integer"}, {"name": "recent", "in": "query", "description": "Show challenges that have not ended in the last N weeks", "required": false, "type": "integer"}], "responses": {"200": {"description": "", "schema": {"required": ["count", "results"], "type": "object", "properties": {"count": {"type": "integer"}, "next": {"type": "string", "format": "uri", "x-nullable": true}, "previous": {"type": "string", "format": "uri", "x-nullable": true}, "results": {"type": "array", "items": {"$ref": "#/definitions/ChallengeList"}}}}}}, "tags": ["challenge"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "post": {"operationId": "challenge_create", "summary": "Create challenge", "description": "Creates a new challenge", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/ChallengeDetail"}}], "responses": {"201": {"description": "", "schema": {"$ref": "#/definitions/ChallengeDetail"}}}, "tags": ["challenge"], "security": [{"BearerAdmin": []}], "deprecated": false}, "parameters": []}, "/challenge/{challenge_public_id}/team/": {"get": {"operationId": "challenge_team_list", "summary": "Team leaderboard", "description": "List the standings of different teams in challenges (don't have to be team challenges).\nThis endpoint returns a list of objects.\n", "parameters": [{"name": "limit", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "offset", "in": "query", "description": "The initial index from which to return the results.", "required": false, "type": "integer"}, {"name": "date_range", "in": "query", "description": "Index of the time period use", "required": false, "type": "integer"}], "responses": {"200": {"description": "", "schema": {"required": ["count", "results"], "type": "object", "properties": {"count": {"type": "integer"}, "next": {"type": "string", "format": "uri", "x-nullable": true}, "previous": {"type": "string", "format": "uri", "x-nullable": true}, "results": {"type": "array", "items": {"$ref": "#/definitions/LeaderboardTeam"}}}}}}, "tags": ["challenge"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "parameters": [{"name": "challenge_public_id", "in": "path", "required": true, "type": "string"}]}, "/challenge/{challenge_public_id}/team/{team_public_id}/": {"get": {"operationId": "challenge_team_read", "summary": "Team contribution", "description": "List team members' contribution to the challenge.\nThis endpoint returns a list of objects.\n", "parameters": [{"name": "date_range", "in": "query", "description": "Index of the time period use", "required": false, "type": "integer"}], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/LeaderboardProfile"}}}, "tags": ["challenge"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "parameters": [{"name": "challenge_public_id", "in": "path", "required": true, "type": "string"}, {"name": "team_public_id", "in": "path", "required": true, "type": "string"}]}, "/challenge/{public_id}/": {"get": {"operationId": "challenge_read", "summary": "Get Challenge", "description": "Gets a single challenge", "parameters": [], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/ChallengeDetail"}}}, "tags": ["challenge"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "put": {"operationId": "challenge_update", "summary": "Edit challenge", "description": "Edits a challenge", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/ChallengeDetail"}}], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/ChallengeDetail"}}}, "tags": ["challenge"], "security": [{"BearerAdmin": []}], "deprecated": false}, "patch": {"operationId": "challenge_partial_update", "summary": "Partial edit challenge", "description": "Edits a challenge", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/ChallengeDetail"}}], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/ChallengeDetail"}}}, "tags": ["challenge"], "security": [{"BearerAdmin": []}], "deprecated": false}, "delete": {"operationId": "challenge_delete", "summary": "Delete challenge", "description": "deletes a challenge", "parameters": [], "responses": {"204": {"description": ""}}, "tags": ["challenge"], "security": [{"BearerAdmin": []}], "deprecated": false}, "parameters": [{"name": "public_id", "in": "path", "required": true, "type": "string"}]}, "/challenge/{public_id}/deactivate_member/": {"post": {"operationId": "challenge_deactivate_member_create", "summary": "Deactivate member", "description": "Deactivate a member from the challenge", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/ProfileAsProfilePublicIdAndTeamAsTeamPublicId"}}, {"name": "profile", "in": "query", "description": "A profile public_id is expected", "required": true, "type": "string", "format": "uuid"}, {"name": "team", "in": "query", "description": "A team public_id is expected", "required": false, "type": "string", "format": "uuid"}, {"name": "is_active", "in": "query", "description": "Whether profile actively participates in challenge.\n\nWhile inactive, scores/leaderboard will not be updated but still be visible.", "required": false, "type": "boolean"}], "responses": {"201": {"description": "", "schema": {"$ref": "#/definitions/ProfileAsProfilePublicIdAndTeamAsTeamPublicId"}}}, "tags": ["challenge"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "put": {"operationId": "challenge_deactivate_member_update", "description": "This docstring is used by Django Rest Framework", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/ProfileAsProfilePublicIdAndTeamAsTeamPublicId"}}], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/ProfileAsProfilePublicIdAndTeamAsTeamPublicId"}}}, "tags": ["challenge"]}, "parameters": [{"name": "public_id", "in": "path", "required": true, "type": "string"}]}, "/challenge/{public_id}/deactivate_members/": {"post": {"operationId": "challenge_deactivate_members_create", "summary": "Deactivate members", "description": "Deactivate multiple members from the challenge", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/ProfilePublicIdsListAndTeamAsPublicId"}}, {"name": "profile", "in": "query", "description": "A profile public_id is expected", "required": true, "type": "string", "format": "uuid"}, {"name": "team", "in": "query", "description": "A team public_id is expected", "required": false, "type": "string", "format": "uuid"}, {"name": "is_active", "in": "query", "description": "Whether profile actively participates in challenge.\n\nWhile inactive, scores/leaderboard will not be updated but still be visible.", "required": false, "type": "boolean"}], "responses": {"201": {"description": "", "schema": {"$ref": "#/definitions/ProfilePublicIdsListAndTeamAsPublicId"}}}, "tags": ["challenge"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "put": {"operationId": "challenge_deactivate_members_update", "description": "This docstring is used by Django Rest Framework", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/ProfilePublicIdsListAndTeamAsPublicId"}}], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/ProfilePublicIdsListAndTeamAsPublicId"}}}, "tags": ["challenge"]}, "parameters": [{"name": "public_id", "in": "path", "required": true, "type": "string"}]}, "/challenge/{public_id}/leaderboard/": {"get": {"operationId": "challenge_leaderboard", "summary": "Leaderboard", "description": "Displays the leaderboard for a challenge.\nThis endpoint returns a list of objects.\n", "parameters": [{"name": "date_range", "in": "query", "description": "Index of the time period use", "required": false, "type": "integer"}], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/LeaderboardProfileAndTeam"}}}, "tags": ["challenge"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "parameters": [{"name": "public_id", "in": "path", "required": true, "type": "string"}]}, "/challenge/{public_id}/leaderboard_history/": {"get": {"operationId": "challenge_leaderboard_history", "summary": "Leaderboard history", "description": "Retrieve the scores of the authenticated profile for all periods since the profile joined the challenge.\nThis endpoint returns a list of objects.\n", "parameters": [], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/LeaderboardHistory"}}}, "tags": ["challenge"], "security": [{"BearerProfile": []}], "deprecated": false}, "parameters": [{"name": "public_id", "in": "path", "required": true, "type": "string"}]}, "/challenge/{public_id}/member/": {"post": {"operationId": "challenge_member_create", "summary": "Add member", "description": "Add member to a team.\n\nNote: for now if the challenge is a team challenge and no team is specified, the first team for the specified profile is\nused. Do note that this is a temporary fix and may be removed at any time.\n", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/ProfileAsProfilePublicIdAndTeamAsTeamPublicId"}}], "responses": {"201": {"description": "", "schema": {"$ref": "#/definitions/ProfileAsProfilePublicIdAndTeamAsTeamPublicId"}}}, "tags": ["challenge"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "put": {"operationId": "challenge_member_update", "summary": "Add member", "description": "Add member to a team.\n\nNote: for now if the challenge is a team challenge and no team is specified, the first team for the specified profile is\nused. Do note that this is a temporary fix and may be removed at any time.\n", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/ProfileAsProfilePublicIdAndTeamAsTeamPublicId"}}], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/ProfileAsProfilePublicIdAndTeamAsTeamPublicId"}}}, "tags": ["challenge"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "delete": {"operationId": "challenge_member_delete", "summary": "Remove member", "description": "Remove a member from the challenge", "parameters": [{"name": "profile", "in": "query", "description": "A profile public_id is expected", "required": true, "type": "string", "format": "uuid"}], "responses": {"204": {"description": ""}}, "tags": ["challenge"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "parameters": [{"name": "public_id", "in": "path", "required": true, "type": "string"}]}, "/challenge/{public_id}/members/": {"get": {"operationId": "challenge_members_read", "summary": "Get members", "description": "Get a paginated list of members enrolled to a Challenge", "parameters": [], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/ChallengeDetail"}}}, "tags": ["challenge"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "post": {"operationId": "challenge_members_create", "summary": "Add members", "description": "Add members to a team.\n\nNote: for now if the challenge is a team challenge and no team is specified, the first team for the specified profile is\nused. Do note that this is a temporary fix and may be removed at any time.\n\nNote: for the GET/POST endpoint an admin bearer token is required, while the GET also accepts profile bearer tokens", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/ProfilePublicIdsListAndTeamAsPublicId"}}], "responses": {"201": {"description": "", "schema": {"$ref": "#/definitions/ProfilePublicIdsListAndTeamAsPublicId"}}}, "tags": ["challenge"], "security": [{"BearerAdmin": []}], "deprecated": false}, "put": {"operationId": "challenge_members_update", "summary": "Add members", "description": "Add members to a team.\n\nNote: for now if the challenge is a team challenge and no team is specified, the first team for the specified profile is\nused. Do note that this is a temporary fix and may be removed at any time.\n\nNote: for the GET/POST endpoint an admin bearer token is required, while the GET also accepts profile bearer tokens", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/ProfilePublicIdsListAndTeamAsPublicId"}}], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/ProfilePublicIdsListAndTeamAsPublicId"}}}, "tags": ["challenge"], "security": [{"BearerAdmin": []}], "deprecated": false}, "parameters": [{"name": "public_id", "in": "path", "required": true, "type": "string"}]}, "/challenge/{public_id}/periods/": {"get": {"operationId": "challenge_periods", "summary": "Periods", "description": "Get all periods for the challenge.\nThis endpoint returns a list of objects.\n", "parameters": [], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/ChallengePeriod"}}}, "tags": ["challenge"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "parameters": [{"name": "public_id", "in": "path", "required": true, "type": "string"}]}, "/challenge/{public_id}/remove_members/": {"post": {"operationId": "challenge_remove_members", "summary": "Remove members", "description": "Remove members from the challenge", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/ProfilePublicIdsListAndTeamAsPublicId"}}], "responses": {"201": {"description": "", "schema": {"$ref": "#/definitions/ProfilePublicIdsListAndTeamAsPublicId"}}}, "tags": ["challenge"], "security": [{"BearerAdmin": []}], "deprecated": false}, "parameters": [{"name": "public_id", "in": "path", "required": true, "type": "string"}]}, "/connection/{connection_slug}/connect/": {"post": {"operationId": "connection_connect_create", "summary": "Connect wearable", "description": "Get OAuth URL for this connection.", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/ProfileAsProfilePublicId"}}], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/AppConnectionUrl"}}}, "tags": ["connection"], "deprecated": false}, "delete": {"operationId": "connection_connect_delete", "summary": "Disconnect Wearable", "description": "Disconnect a wearables connection", "parameters": [{"name": "profile", "in": "query", "description": "A profile public_id is expected", "required": true, "type": "string", "format": "uuid"}], "responses": {"200": {"description": "OK"}}, "tags": ["connection"], "deprecated": false}, "parameters": [{"name": "connection_slug", "in": "path", "required": true, "type": "string"}]}, "/insights/bio_age": {"get": {"operationId": "insights_bio_age_read", "summary": "Get someones biological age on a weekly basis.", "description": "", "parameters": [{"name": "start_date", "in": "query", "required": true, "type": "string", "format": "date"}, {"name": "end_date", "in": "query", "required": true, "type": "string", "format": "date"}], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/BioAge"}}}}, "tags": ["insights"]}, "parameters": []}, "/loyalty/get_recommended_products": {"get": {"operationId": "loyalty_get_recommended_products_list", "description": "", "parameters": [{"name": "limit", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "offset", "in": "query", "description": "The initial index from which to return the results.", "required": false, "type": "integer"}], "responses": {"200": {"description": "", "schema": {"required": ["count", "results"], "type": "object", "properties": {"count": {"type": "integer"}, "next": {"type": "string", "format": "uri", "x-nullable": true}, "previous": {"type": "string", "format": "uri", "x-nullable": true}, "results": {"type": "array", "items": {"$ref": "#/definitions/RecommendedProducts"}}}}}}, "tags": ["loyalty"]}, "parameters": []}, "/loyalty/get_shoppingcart_link": {"get": {"operationId": "loyalty_get_shoppingcart_link_read", "description": "", "parameters": [], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/ShoppingCart"}}}, "tags": ["loyalty"]}, "parameters": []}, "/notification/send_to_all/": {"post": {"operationId": "notification_send_to_all_create", "summary": "Notification to all profiles in app", "description": "Send a notification to all registered devices in the app.", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/Notification"}}], "responses": {"201": {"description": "", "schema": {"$ref": "#/definitions/Notification"}}}, "tags": ["notification"], "security": [{"BearerAdmin": []}], "deprecated": false}, "parameters": []}, "/notification/send_to_profiles/": {"post": {"operationId": "notification_send_to_profiles_create", "summary": "Notification to specific profiles", "description": "Send a notification to all registered devices for the specified profiles.", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/NotificationForProfiles"}}], "responses": {"201": {"description": "", "schema": {"$ref": "#/definitions/NotificationForProfiles"}}}, "tags": ["notification"], "security": [{"BearerAdmin": []}], "deprecated": false}, "parameters": []}, "/profile/": {"get": {"operationId": "profile_list", "summary": "List Profiles", "description": "Lists all available profiles", "parameters": [{"name": "search", "in": "query", "description": "A search term.", "required": false, "type": "string"}, {"name": "ordering", "in": "query", "description": "Which field to use when ordering the results.", "required": false, "type": "string"}, {"name": "limit", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "offset", "in": "query", "description": "The initial index from which to return the results.", "required": false, "type": "integer"}], "responses": {"200": {"description": "", "schema": {"required": ["count", "results"], "type": "object", "properties": {"count": {"type": "integer"}, "next": {"type": "string", "format": "uri", "x-nullable": true}, "previous": {"type": "string", "format": "uri", "x-nullable": true}, "results": {"type": "array", "items": {"$ref": "#/definitions/ProfileList"}}}}}}, "tags": ["profile"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "post": {"operationId": "profile_create", "summary": "Create Profile", "description": "\nCreates a new profile.\nThe bearer field contains a profile bearer token. When this is used in the Authorization header actions are performed\nas that profile, which will also enable access to private data.\nUsing a profile bearer token disables administrative features such as creating profiles, making this token safe\nfor 'public' use.\nA profile bearer token has no expiration, so it remains valid as long as the profile is active.\n", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/ProfileCreated"}}], "responses": {"201": {"description": "", "schema": {"$ref": "#/definitions/ProfileCreated"}}}, "tags": ["profile"], "security": [{"BearerAdmin": []}], "deprecated": false}, "parameters": []}, "/profile/{profile_public_id}/activity_file/": {"get": {"operationId": "profile_activity_file_list", "description": "", "parameters": [], "responses": {"200": {"description": ""}}, "tags": ["profile"]}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/activity_file/{activity_id}": {"get": {"operationId": "profile_activity_file_read", "description": "", "parameters": [], "responses": {"200": {"description": ""}}, "tags": ["profile"]}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}, {"name": "activity_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/activity_segment/": {"get": {"operationId": "profile_activity_segment_list", "summary": "Activity segment", "description": "Lists segments of activities and small non-workout-like movements.", "parameters": [{"name": "cursor", "in": "query", "description": "The pagination cursor value.", "required": false, "type": "string"}, {"name": "page_size", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "date_start", "in": "query", "description": "Lower bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "date_end", "in": "query", "description": "Upper bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/Activity"}}, "headers": {"api-results-next": {"description": "Next page.", "type": "string"}, "api-results-previous": {"description": "Previous page.", "type": "string"}}}}, "tags": ["profile"], "deprecated": false}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/biometric/": {"get": {"operationId": "profile_biometric_list", "summary": "Bio Metric", "description": "Lists changes in weight, height and bmi for the profile.", "parameters": [{"name": "cursor", "in": "query", "description": "The pagination cursor value.", "required": false, "type": "string"}, {"name": "page_size", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "date_start", "in": "query", "description": "Lower bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "date_end", "in": "query", "description": "Upper bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/BioMetric"}}, "headers": {"api-results-next": {"description": "Next page.", "type": "string"}, "api-results-previous": {"description": "Previous page.", "type": "string"}}}}, "tags": ["profile"], "deprecated": false}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/biometric_measurement/": {"get": {"operationId": "profile_biometric_measurement_list", "summary": "Biometric Measurement", "description": "List changes in biometric measurements for the profile.", "parameters": [{"name": "cursor", "in": "query", "description": "The pagination cursor value.", "required": false, "type": "string"}, {"name": "page_size", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "date_start", "in": "query", "description": "Lower bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "date_end", "in": "query", "description": "Upper bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "measurement_type", "in": "query", "required": true, "type": "string", "enum": ["BLOOD_PRESSURE", "BODY_FAT", "BODY_FAT_MASS", "GLUCOSE", "SYSTOLIC_BP", "DIASTOLIC_BP", "PULSE_BP", "TEMPERATURE", "BLOOD_OXYGEN", "HRV", "VO2_MAX", "METABOLIC_AGE", "VASCULAR_AGE", "VISCERAL_FAT", "BODY_TEMPERATURE", "SKIN_TEMPERATURE", "BONE_MASS", "MUSCLE_MASS", "HYDRATION", "BMR", "FAT_RATIO", "SPO2", "OTHER"]}], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/BiometricMeasurement"}}, "headers": {"api-results-next": {"description": "Next page.", "type": "string"}, "api-results-previous": {"description": "Previous page.", "type": "string"}}}}, "tags": ["profile"], "deprecated": false}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/bmi/": {"get": {"operationId": "profile_bmi_list", "summary": "BMI", "description": "Presents the Body-Mass-Index over time.", "parameters": [{"name": "cursor", "in": "query", "description": "The pagination cursor value.", "required": false, "type": "string"}, {"name": "page_size", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "date_start", "in": "query", "description": "Lower bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "date_end", "in": "query", "description": "Upper bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/BMI"}}, "headers": {"api-results-next": {"description": "Next page.", "type": "string"}, "api-results-previous": {"description": "Previous page.", "type": "string"}}}}, "tags": ["profile"], "deprecated": false}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/daily_detail/": {"get": {"operationId": "profile_daily_detail_list", "summary": "Daily details", "description": "Intraday data measured at a single point in time.", "parameters": [{"name": "cursor", "in": "query", "description": "The pagination cursor value.", "required": false, "type": "string"}, {"name": "page_size", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "date_start", "in": "query", "description": "Lower bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "date_end", "in": "query", "description": "Upper bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/DailyDetail"}}, "headers": {"api-results-next": {"description": "Next page.", "type": "string"}, "api-results-previous": {"description": "Previous page.", "type": "string"}}}}, "tags": ["profile"], "deprecated": false}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/daily_summary/": {"get": {"operationId": "profile_daily_summary_list", "summary": "Daily Summary", "description": "Provides summarized data per day.", "parameters": [{"name": "cursor", "in": "query", "description": "The pagination cursor value.", "required": false, "type": "string"}, {"name": "page_size", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "date_start", "in": "query", "description": "Lower bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "date_end", "in": "query", "description": "Upper bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "deduplicate", "in": "query", "description": "If set to true, duplicates will be aggregated.", "required": false, "type": "boolean"}], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/DailySummary"}}, "headers": {"api-results-next": {"description": "Next page.", "type": "string"}, "api-results-previous": {"description": "Previous page.", "type": "string"}}}}, "tags": ["profile"], "deprecated": false}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/detail_sample/": {"get": {"operationId": "profile_detail_sample_list", "summary": "Detail Sample", "description": "Presents detail samples.", "parameters": [{"name": "cursor", "in": "query", "description": "The pagination cursor value.", "required": false, "type": "string"}, {"name": "page_size", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "date_start", "in": "query", "description": "Lower bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "date_end", "in": "query", "description": "Upper bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/DetailSample"}}, "headers": {"api-results-next": {"description": "Next page.", "type": "string"}, "api-results-previous": {"description": "Previous page.", "type": "string"}}}}, "tags": ["profile"], "deprecated": false}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/ecg_recordings/": {"get": {"operationId": "profile_ecg_recordings_list", "summary": "Electrocardiograms", "description": "\nThis endpoint returns a list of ECG recordings.\n", "parameters": [{"name": "cursor", "in": "query", "description": "The pagination cursor value.", "required": false, "type": "string"}, {"name": "page_size", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "date_start", "in": "query", "description": "Lower bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "date_end", "in": "query", "description": "Upper bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/ECGRecordings"}}, "headers": {"api-results-next": {"description": "Next page.", "type": "string"}, "api-results-previous": {"description": "Previous page.", "type": "string"}}}}, "tags": ["profile"], "deprecated": false}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/ecg_recordings/data/": {"get": {"operationId": "profile_ecg_recordings_data_list", "summary": "Electrocardiogram data", "description": "\nThis endpoint returns an ECG recording with data as an array of tuples `[(time, value)]`.\nSet the argument `date_end` to request a specific recording or leave it empty to receive the latest recording.\n", "parameters": [{"name": "cursor", "in": "query", "description": "The pagination cursor value.", "required": false, "type": "string"}, {"name": "page_size", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "date_start", "in": "query", "description": "Lower bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "date_end", "in": "query", "description": "Upper bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/ECGRecording"}}, "headers": {"api-results-next": {"description": "Next page.", "type": "string"}, "api-results-previous": {"description": "Previous page.", "type": "string"}}}}, "tags": ["profile"], "deprecated": false}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/ecg_recordings/pdf/": {"get": {"operationId": "profile_ecg_recordings_pdf_list", "summary": "Electrocardiogram PDF", "description": "Returns a PDF with generated ECG charts from a specific source and time. Contact api-support@wefitter.com to gain access.", "parameters": [{"name": "datetime", "in": "query", "description": "The timestamp when the ECG has been recorded in the format `yyyymmddhhmmss`. e.g. `20210913132513`", "required": true, "type": "string", "format": "date-time"}, {"name": "source", "in": "query", "required": true, "type": "string", "enum": ["NONE", "AGGREGATED", "ANDROID", "APPLE", "FITBIT", "GARMIN", "GOOGLE_HEALTH", "GOOGLEFIT", "HEALTHCONNECT", "HUAWEI", "MYZONE", "OMH", "OMRON", "OURA", "POLAR", "SAMSUNG", "STRAVA", "SUUNTO", "WF", "WHOOP", "WITHINGS"]}], "responses": {"200": {"description": ""}}, "tags": ["profile"], "security": [{"BearerProfile": []}], "deprecated": false}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/event/": {"get": {"operationId": "profile_event_list", "summary": "Event", "description": "Lists events, generic actions for which points have been awarded.", "parameters": [{"name": "cursor", "in": "query", "description": "The pagination cursor value.", "required": false, "type": "string"}, {"name": "page_size", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "date_start", "in": "query", "description": "Lower bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "date_end", "in": "query", "description": "Upper bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/Event"}}, "headers": {"api-results-next": {"description": "Next page.", "type": "string"}, "api-results-previous": {"description": "Previous page.", "type": "string"}}}}, "tags": ["profile"], "deprecated": false}, "post": {"operationId": "profile_event_create", "summary": "Create Event", "description": "Create a new event for the profile.", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/Event"}}], "responses": {"201": {"description": "", "schema": {"$ref": "#/definitions/Event"}}}, "tags": ["profile"], "security": [{"BearerAdmin": []}], "deprecated": false}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/heartrate_sample/": {"get": {"operationId": "profile_heartrate_sample_list", "summary": "Heart Rate Sample", "description": "Heart Rate measured at a single point in time.", "parameters": [{"name": "cursor", "in": "query", "description": "The pagination cursor value.", "required": false, "type": "string"}, {"name": "page_size", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "date_start", "in": "query", "description": "Lower bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "date_end", "in": "query", "description": "Upper bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "heart_rate_detail", "in": "query", "description": "If set to true it will add heart_rate_samples field", "required": false, "type": "boolean"}], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/HeartRateSample"}}, "headers": {"api-results-next": {"description": "Next page.", "type": "string"}, "api-results-previous": {"description": "Previous page.", "type": "string"}}}}, "tags": ["profile"], "deprecated": false}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/heartrate_summary/": {"get": {"operationId": "profile_heartrate_summary_list", "summary": "Heart Rate Summary", "description": "Presents heart rate information.", "parameters": [{"name": "cursor", "in": "query", "description": "The pagination cursor value.", "required": false, "type": "string"}, {"name": "page_size", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "date_start", "in": "query", "description": "Lower bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "date_end", "in": "query", "description": "Upper bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/HeartRateSummary"}}, "headers": {"api-results-next": {"description": "Next page.", "type": "string"}, "api-results-previous": {"description": "Previous page.", "type": "string"}}}}, "tags": ["profile"], "deprecated": false}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/height/": {"get": {"operationId": "profile_height_list", "summary": "Height", "description": "Lists changes in height for the profile.", "parameters": [{"name": "cursor", "in": "query", "description": "The pagination cursor value.", "required": false, "type": "string"}, {"name": "page_size", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "date_start", "in": "query", "description": "Lower bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "date_end", "in": "query", "description": "Upper bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/Height"}}, "headers": {"api-results-next": {"description": "Next page.", "type": "string"}, "api-results-previous": {"description": "Previous page.", "type": "string"}}}}, "tags": ["profile"], "deprecated": false}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/sleep_detail/": {"get": {"operationId": "profile_sleep_detail_list", "summary": "Sleep detail", "description": "Provides sleep detail data.", "parameters": [{"name": "cursor", "in": "query", "description": "The pagination cursor value.", "required": false, "type": "string"}, {"name": "page_size", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "date_start", "in": "query", "description": "Lower bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "date_end", "in": "query", "description": "Upper bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/SleepDetail"}}, "headers": {"api-results-next": {"description": "Next page.", "type": "string"}, "api-results-previous": {"description": "Previous page.", "type": "string"}}}}, "tags": ["profile"], "deprecated": false}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/sleep_sample/": {"get": {"operationId": "profile_sleep_sample_list", "summary": "Sleep Sample", "description": "Presents sample data for sleep: hrv, movement, heart_rate and sleep_stages,", "parameters": [{"name": "cursor", "in": "query", "description": "The pagination cursor value.", "required": false, "type": "string"}, {"name": "page_size", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "date_start", "in": "query", "description": "Lower bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "date_end", "in": "query", "description": "Upper bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/SleepSample"}}, "headers": {"api-results-next": {"description": "Next page.", "type": "string"}, "api-results-previous": {"description": "Previous page.", "type": "string"}}}}, "tags": ["profile"], "deprecated": false}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/sleep_summary/": {"get": {"operationId": "profile_sleep_summary_list", "summary": "Sleep Summary", "description": "Provides summarized sleep data.", "parameters": [{"name": "cursor", "in": "query", "description": "The pagination cursor value.", "required": false, "type": "string"}, {"name": "page_size", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "date_start", "in": "query", "description": "Lower bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "date_end", "in": "query", "description": "Upper bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "detail", "in": "query", "description": "If set to true and only 1 result is returned, it will add a detail field", "required": false, "type": "boolean"}], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/SleepSummary"}}, "headers": {"api-results-next": {"description": "Next page.", "type": "string"}, "api-results-previous": {"description": "Previous page.", "type": "string"}}}}, "tags": ["profile"], "deprecated": false}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/stress_samples/": {"get": {"operationId": "profile_stress_samples_list", "summary": "Stress Sample", "description": "Presents stress samples.", "parameters": [{"name": "cursor", "in": "query", "description": "The pagination cursor value.", "required": false, "type": "string"}, {"name": "page_size", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "date_start", "in": "query", "description": "Lower bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "date_end", "in": "query", "description": "Upper bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/StressSample"}}, "headers": {"api-results-next": {"description": "Next page.", "type": "string"}, "api-results-previous": {"description": "Previous page.", "type": "string"}}}}, "tags": ["profile"], "deprecated": false}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/stress_summary/": {"get": {"operationId": "profile_stress_summary_list", "summary": "Stress Summary", "description": "Presents stress summaries.", "parameters": [{"name": "cursor", "in": "query", "description": "The pagination cursor value.", "required": false, "type": "string"}, {"name": "page_size", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "date_start", "in": "query", "description": "Lower bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "date_end", "in": "query", "description": "Upper bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/StressSummary"}}, "headers": {"api-results-next": {"description": "Next page.", "type": "string"}, "api-results-previous": {"description": "Previous page.", "type": "string"}}}}, "tags": ["profile"], "deprecated": false}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/track_sample/": {"get": {"operationId": "profile_track_sample_list", "summary": "Track Sample", "description": "Presents GPX track samples.", "parameters": [{"name": "cursor", "in": "query", "description": "The pagination cursor value.", "required": false, "type": "string"}, {"name": "page_size", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "date_start", "in": "query", "description": "Lower bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "date_end", "in": "query", "description": "Upper bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/TrackSample"}}, "headers": {"api-results-next": {"description": "Next page.", "type": "string"}, "api-results-previous": {"description": "Previous page.", "type": "string"}}}}, "tags": ["profile"], "deprecated": false}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/weight/": {"get": {"operationId": "profile_weight_list", "summary": "Weight", "description": "Lists changes in weight for the profile.", "parameters": [{"name": "cursor", "in": "query", "description": "The pagination cursor value.", "required": false, "type": "string"}, {"name": "page_size", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "date_start", "in": "query", "description": "Lower bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "date_end", "in": "query", "description": "Upper bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/Weight"}}, "headers": {"api-results-next": {"description": "Next page.", "type": "string"}, "api-results-previous": {"description": "Previous page.", "type": "string"}}}}, "tags": ["profile"], "deprecated": false}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{profile_public_id}/workout/": {"get": {"operationId": "profile_workout_list", "summary": "Workout", "description": "Lists workouts associated with the profile. Used to be known as Activity.", "parameters": [{"name": "cursor", "in": "query", "description": "The pagination cursor value.", "required": false, "type": "string"}, {"name": "page_size", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "date_start", "in": "query", "description": "Lower bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "date_end", "in": "query", "description": "Upper bound of date or timestamp.", "required": false, "type": "string", "format": "date-time"}, {"name": "deduplicate", "in": "query", "description": "If set to true, duplicates will be aggregated.", "required": false, "type": "boolean"}, {"name": "heart_rate_detail", "in": "query", "description": "If set to true and page_size is 1, it will add heart_rate_samples field", "required": false, "type": "boolean"}], "responses": {"200": {"description": "", "schema": {"type": "array", "items": {"$ref": "#/definitions/Workout"}}, "headers": {"api-results-next": {"description": "Next page.", "type": "string"}, "api-results-previous": {"description": "Previous page.", "type": "string"}}}}, "tags": ["profile"], "deprecated": false}, "parameters": [{"name": "profile_public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{public_id}/": {"get": {"operationId": "profile_read", "summary": "Get Profile", "description": "Gets a single profile", "parameters": [], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/ProfileDetail"}}}, "tags": ["profile"], "deprecated": false}, "put": {"operationId": "profile_update", "summary": "Update profile", "description": "Updates the specified profile, excluding ID, team and public id.", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/ProfileDetail"}}], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/ProfileDetail"}}}, "tags": ["profile"], "deprecated": false}, "patch": {"operationId": "profile_partial_update", "summary": "Partial Update", "description": "Performs a partial update", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/ProfileDetail"}}], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/ProfileDetail"}}}, "tags": ["profile"], "deprecated": false}, "delete": {"operationId": "profile_delete", "summary": "Delete Profile", "description": "Deletes the specified profile, if created by the app.", "parameters": [], "responses": {"204": {"description": ""}}, "tags": ["profile"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "parameters": [{"name": "public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{public_id}/challenge/": {"get": {"operationId": "profile_challenge", "summary": "Challenge", "description": "Provides a list of challenges where the profile can participate and is already participating in.\n\nThis endpoint returns a list of objects.\n", "parameters": [{"name": "recent", "in": "query", "description": "Show challenges that have not ended in the last N weeks", "required": false, "type": "integer"}, {"name": "date_start", "in": "query", "description": "Only return challenges that are active after this time\n\nNote: this only affects challenges that are not joined.\n\nDefaults to now", "required": false, "type": "string", "format": "date-time", "x-nullable": true}, {"name": "date_end", "in": "query", "description": "Only return challenges that are active before this time\n\nNote: this only affects challenges that are not joined.\n\nDefaults to now", "required": false, "type": "string", "format": "date-time", "x-nullable": true}], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/ProfileChallengeList"}}}, "tags": ["profile"], "deprecated": false}, "parameters": [{"name": "public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{public_id}/challenges/": {"get": {"operationId": "profile_challenges", "description": "This docstring is used by Django Rest Framework", "parameters": [], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/ProfileChallengeList"}}}, "tags": ["profile"]}, "parameters": [{"name": "public_id", "in": "path", "required": true, "type": "string"}]}, "/profile/{public_id}/connections/": {"get": {"operationId": "profile_connections", "summary": "Connections", "description": "Lists the connections available for a profile and their \"state\".\nThis endpoint returns a list of objects.\n", "parameters": [{"name": "redirect", "in": "query", "description": "After connecting redirect back to this url.\n\nNote: has to be a valid http url. For deeplinks (to apps) first redirect to your own backend and then deeplink from there.\n\nNote: the user is only redirected on a successfull connection, otherwise an error screen is shown. (see redirect_on_error to change this)\n\nNote: if this parameter is omitted, then user will see a generic success screen.", "required": false, "type": "string", "minLength": 1}, {"name": "redirect_on_error", "in": "query", "description": "If enabled, then user will also be redirected to the redirect url if an error occurs\n\nNote: a query parameter 'error' is added to the redirect url. Possible values are access_denied, unknown. New values may be added at anytime\n\nNote: for backwards compatibility the default is false, but this will be changed in the next breaking release", "required": false, "type": "boolean"}], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/ProfileAppConnectionList"}}}, "tags": ["profile"], "deprecated": false}, "parameters": [{"name": "public_id", "in": "path", "required": true, "type": "string"}]}, "/team/": {"get": {"operationId": "team_list", "summary": "List Teams", "description": "List all available teams", "parameters": [{"name": "limit", "in": "query", "description": "Number of results to return per page.", "required": false, "type": "integer"}, {"name": "offset", "in": "query", "description": "The initial index from which to return the results.", "required": false, "type": "integer"}], "responses": {"200": {"description": "", "schema": {"required": ["count", "results"], "type": "object", "properties": {"count": {"type": "integer"}, "next": {"type": "string", "format": "uri", "x-nullable": true}, "previous": {"type": "string", "format": "uri", "x-nullable": true}, "results": {"type": "array", "items": {"$ref": "#/definitions/TeamList"}}}}}}, "tags": ["team"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "post": {"operationId": "team_create", "summary": "Create Team", "description": "Creates a new team", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/TeamDetail"}}], "responses": {"201": {"description": "", "schema": {"$ref": "#/definitions/TeamDetail"}}}, "tags": ["team"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "parameters": []}, "/team/{public_id}/": {"get": {"operationId": "team_read", "summary": "Team", "description": "Get a single team", "parameters": [], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/TeamDetail"}}}, "tags": ["team"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "put": {"operationId": "team_update", "summary": "Edit Team", "description": "Creates a new team", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/TeamDetail"}}], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/TeamDetail"}}}, "tags": ["team"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "patch": {"operationId": "team_partial_update", "summary": "Partial Edit a Team", "description": "Creates a new team", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/TeamDetail"}}], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/TeamDetail"}}}, "tags": ["team"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "delete": {"operationId": "team_delete", "summary": "Deletes a Team", "description": "Deletes an existing team", "parameters": [], "responses": {"204": {"description": ""}}, "tags": ["team"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "parameters": [{"name": "public_id", "in": "path", "required": true, "type": "string"}]}, "/team/{public_id}/member/": {"post": {"operationId": "team_member_create", "summary": "Add member", "description": "Add member to a team", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/ProfileAsProfilePublicId"}}], "responses": {"201": {"description": "", "schema": {"$ref": "#/definitions/ProfileAsProfilePublicId"}}}, "tags": ["team"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "put": {"operationId": "team_member_update", "summary": "Add member", "description": "Add member to a team", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/ProfileAsProfilePublicId"}}], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/ProfileAsProfilePublicId"}}}, "tags": ["team"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "delete": {"operationId": "team_member_delete", "summary": "Remove member", "description": "Remove a member from the team", "parameters": [{"name": "profile", "in": "query", "description": "A profile public_id is expected", "required": true, "type": "string", "format": "uuid"}], "responses": {"204": {"description": ""}}, "tags": ["team"], "security": [{"BearerAdmin": []}, {"BearerProfile": []}], "deprecated": false}, "parameters": [{"name": "public_id", "in": "path", "required": true, "type": "string"}]}, "/team/{public_id}/members/": {"post": {"operationId": "team_members_create", "summary": "Add members", "description": "Add members to a team", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/ProfilePublicIdsList"}}], "responses": {"201": {"description": "", "schema": {"$ref": "#/definitions/ProfilePublicIdsList"}}}, "tags": ["team"], "security": [{"BearerAdmin": []}], "deprecated": false}, "put": {"operationId": "team_members_update", "summary": "Add members", "description": "Add members to a team", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/ProfilePublicIdsList"}}], "responses": {"200": {"description": "", "schema": {"$ref": "#/definitions/ProfilePublicIdsList"}}}, "tags": ["team"], "security": [{"BearerAdmin": []}], "deprecated": false}, "parameters": [{"name": "public_id", "in": "path", "required": true, "type": "string"}]}, "/team/{public_id}/remove_members/": {"post": {"operationId": "team_remove_members", "summary": "Remove members", "description": "Remove members from the team", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/ProfilePublicIdsList"}}], "responses": {"201": {"description": "", "schema": {"$ref": "#/definitions/ProfilePublicIdsList"}}}, "tags": ["team"], "security": [{"BearerAdmin": []}], "deprecated": false}, "parameters": [{"name": "public_id", "in": "path", "required": true, "type": "string"}]}, "/token/": {"post": {"operationId": "token_create", "summary": "Create Token", "description": "\nIn order to create a token, perform a POST request to this endpoint, example:<br/>\n<table><tbody>\n    <tr><td>Application ID</td><td>123</td></tr>\n    <tr><td>Application Secret</td><td>ABC</td></tr>\n    <tr><td>Authorization header format</td><td>Authorization: base64(app_id:app_secret)</td></tr>\n    <tr><td>Expected result</td><td>Authorization: MTIzOkFCQw==</td></tr>\n</tbody></table>\nFor testing purposes, a CURL can be used:\n<pre>\ncurl -X POST -H \"Authorization: Basic MTIzOkFCQw==\" https://api.wefitter.com/api/v1.3/token/\n# alternatively\ncurl -X POST --user 123:ABC https://api.wefitter.com/api/v1.3/token/\n</pre>\n\nThe response to a successful request should look like this:\n<pre>\n{\n    \"bearer\": \"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOiIxNTY2NTYxMzk2IiwiaWF0IjoxNTE2MjM5MDIyfQ.14x12h5VMJjAV2kFB5cCrfFmZhryBAYGk9N-vhyDl00\"\n}\n</pre>\n", "parameters": [{"name": "data", "in": "body", "required": true, "schema": {"$ref": "#/definitions/Token"}}], "responses": {"201": {"description": "", "schema": {"$ref": "#/definitions/Token"}}}, "tags": ["token"], "security": [{"Basic": []}], "deprecated": false}, "parameters": []}}, "definitions": {"AppTotals": {"type": "object", "properties": {"total_calories": {"title": "Total calories", "type": "number"}, "total_distance": {"title": "Total distance", "type": "number"}, "total_steps": {"title": "Total steps", "type": "number"}, "total_points": {"title": "Total points", "type": "number"}, "total_activity_duration": {"title": "Total activity duration", "type": "string <iso8601 duration>", "minLength": 1}}}, "ChallengeList": {"required": ["title", "start", "type", "goal", "goal_type", "visibility"], "type": "object", "properties": {"url": {"title": "Url", "type": "string", "format": "uri", "readOnly": true}, "public_id": {"title": "Public id", "type": "string", "format": "uuid", "readOnly": true}, "title": {"title": "Title", "type": "string", "minLength": 1}, "slogan": {"title": "Slogan", "type": "string"}, "description": {"title": "Description", "type": "string"}, "start": {"title": "Start", "type": "string", "format": "date-time"}, "end": {"title": "End", "type": "string", "format": "date-time", "x-nullable": true}, "type": {"title": "Type", "type": "string", "enum": ["INDIVIDUAL", "GROUP", "TEAM"]}, "goal": {"title": "Goal", "type": "string", "enum": ["DAILY", "TOTAL", "WEEKLY", "MONTHLY"]}, "goal_value": {"title": "Goal value", "type": "integer", "maximum": 2147483647, "minimum": -2147483648, "x-nullable": true}, "goal_type": {"title": "Goal type", "type": "string", "enum": ["POINTS", "DISTANCE", "CALORIES", "DURATION", "STEPS"]}, "visibility": {"title": "Visibility", "type": "string", "enum": ["PUBLIC", "PRIVATE"]}, "num_members": {"title": "Num members", "type": "string", "readOnly": true}}}, "TeamProfile": {"description": "Team which this profile is enrolled with", "required": ["name"], "type": "object", "properties": {"name": {"title": "Name", "type": "string", "maxLength": 100, "minLength": 1}, "public_id": {"title": "Public id", "type": "string", "format": "uuid", "readOnly": true}, "url": {"title": "Url", "type": "string", "format": "uri", "readOnly": true}, "avatar": {"title": "Avatar", "type": "string", "format": "uri", "minLength": 1, "x-nullable": true}}}, "ProfileListWithEnrolledTeam": {"description": "List of all profiles participating in this challenge", "required": ["public_id", "reference"], "type": "object", "properties": {"url": {"title": "Url", "type": "string", "format": "uri", "readOnly": true}, "public_id": {"title": "Public id", "type": "string", "format": "uuid"}, "name": {"title": "Name", "type": "string", "readOnly": true, "minLength": 1}, "gender": {"title": "Gender", "type": "string", "enum": ["M", "F", "X"]}, "team": {"$ref": "#/definitions/TeamProfile"}, "reference": {"title": "Reference", "type": "string", "maxLength": 256, "minLength": 1}, "is_active": {"title": "Is active", "description": "Whether profile actively participates in challenge.\nWhile inactive, scores will not be updated", "type": "boolean", "readOnly": true}}}, "ChallengeDetail": {"required": ["title", "start", "type", "goal", "goal_type", "visibility", "calculation_method", "enrollment_method"], "type": "object", "properties": {"url": {"title": "Url", "type": "string", "format": "uri", "readOnly": true}, "public_id": {"title": "Public id", "type": "string", "format": "uuid", "readOnly": true}, "title": {"title": "Title", "type": "string", "minLength": 1}, "slogan": {"title": "Slogan", "type": "string"}, "description": {"title": "Description", "type": "string"}, "start": {"title": "Start", "type": "string", "format": "date-time"}, "end": {"title": "End", "type": "string", "format": "date-time", "x-nullable": true}, "type": {"title": "Type", "type": "string", "enum": ["INDIVIDUAL", "GROUP", "TEAM"]}, "goal": {"title": "Goal", "type": "string", "enum": ["DAILY", "TOTAL", "WEEKLY", "MONTHLY"]}, "goal_value": {"title": "Goal value", "type": "integer", "maximum": 2147483647, "minimum": -2147483648, "x-nullable": true}, "goal_type": {"title": "Goal type", "type": "string", "enum": ["POINTS", "DISTANCE", "CALORIES", "DURATION", "STEPS"]}, "visibility": {"title": "Visibility", "type": "string", "enum": ["PUBLIC", "PRIVATE"]}, "num_members": {"title": "Num members", "type": "string", "readOnly": true}, "calculation_method": {"title": "Calculation method", "type": "string", "enum": ["SUM", "AVERAGE"]}, "goal_progress": {"title": "Goal progress", "description": "Progress towards the goal, from perspective of profile whose bearer is used for authentication: can be an individual/team/global score. When goal is duration, this is the duration in seconds. When an admin token is used, returns 0.0.", "type": "number", "readOnly": true}, "enrollment_method": {"title": "Enrollment method", "type": "string", "enum": ["AUTOMATIC", "MANUAL"]}, "default_enrollment_time": {"title": "Default enrollment time", "type": "string", "enum": ["CHALLENGE_START", "ENROLLMENT_TIME"]}, "members": {"description": "List of all profiles participating in this challenge", "type": "array", "items": {"$ref": "#/definitions/ProfileListWithEnrolledTeam"}, "readOnly": true}}}, "LeaderboardTeam": {"required": ["name"], "type": "object", "properties": {"name": {"title": "Name", "type": "string", "maxLength": 100, "minLength": 1}, "public_id": {"title": "Public id", "type": "string", "format": "uuid", "readOnly": true}, "url": {"title": "Url", "type": "string", "format": "uri", "readOnly": true}, "num_members": {"title": "Num members", "type": "string", "readOnly": true}, "score": {"title": "Score", "type": "number", "readOnly": true}, "position": {"title": "Position", "type": "integer", "readOnly": true}}}, "LeaderboardProfile": {"type": "object", "properties": {"url": {"title": "Url", "type": "string", "format": "uri", "readOnly": true}, "public_id": {"title": "Public id", "type": "string", "format": "uuid", "readOnly": true}, "name": {"title": "Name", "type": "string", "readOnly": true, "minLength": 1}, "gender": {"title": "Gender", "type": "string", "enum": ["M", "F", "X"]}, "teams": {"description": "Team of which this profile is a member of", "type": "array", "items": {"$ref": "#/definitions/TeamProfile"}, "readOnly": true}, "reference": {"title": "Reference", "type": "string", "readOnly": true, "minLength": 1}, "score": {"title": "Score", "type": "number", "readOnly": true}, "position": {"title": "Position", "type": "integer", "readOnly": true}}}, "ProfileAsProfilePublicIdAndTeamAsTeamPublicId": {"required": ["profile"], "type": "object", "properties": {"profile": {"title": "Profile", "description": "A profile public_id is expected", "type": "string", "format": "uuid"}, "team": {"title": "Team", "description": "A team public_id is expected", "type": "string", "format": "uuid"}, "is_active": {"title": "Is active", "description": "Whether profile actively participates in challenge.\n\nWhile inactive, scores/leaderboard will not be updated but still be visible.", "type": "boolean"}}}, "ProfilePublicIdsListAndTeamAsPublicId": {"required": ["profiles"], "type": "object", "properties": {"profiles": {"type": "array", "items": {"type": "string", "format": "uuid"}}, "is_active": {"title": "Is active", "description": "Whether profile actively participates in challenge.\n\nWhile inactive, scores/leaderboard will not be updated but still be visible.", "type": "boolean"}, "team": {"title": "Team", "description": "A team public_id is expected", "type": "string", "format": "uuid"}}}, "LeaderboardProfileAndTeam": {"type": "object", "properties": {"name": {"title": "Name", "type": "string", "readOnly": true, "minLength": 1}, "public_id": {"title": "Public id", "type": "string", "format": "uuid", "readOnly": true}, "url": {"title": "Url", "type": "string", "format": "uri", "readOnly": true}, "score": {"title": "Score", "type": "number", "readOnly": true}, "position": {"title": "Position", "type": "integer", "readOnly": true}}}, "LeaderboardHistory": {"type": "object", "properties": {"score": {"title": "Score", "type": "number", "readOnly": true}, "start": {"title": "Start", "type": "string", "format": "date-time", "readOnly": true}, "end": {"title": "End", "type": "string", "format": "date-time", "readOnly": true}}}, "ChallengePeriod": {"type": "object", "properties": {"start": {"title": "Start", "type": "string", "format": "date-time", "readOnly": true}, "end": {"title": "End", "type": "string", "format": "date-time", "readOnly": true}}}, "ProfileAsProfilePublicId": {"required": ["profile"], "type": "object", "properties": {"profile": {"title": "Profile", "description": "A profile public_id is expected", "type": "string", "format": "uuid"}}}, "AppConnectionUrl": {"required": ["next"], "type": "object", "properties": {"next": {"title": "Next", "type": "string", "format": "uri", "minLength": 1}}}, "BioAge": {"required": ["start", "end", "bio_age"], "type": "object", "properties": {"start": {"title": "Start", "type": "string", "format": "date"}, "end": {"title": "End", "type": "string", "format": "date"}, "bio_age": {"title": "Bio age", "type": "number"}}}, "RecommendedProducts": {"required": ["name"], "type": "object", "properties": {"article_number": {"title": "Article number", "type": "integer", "maximum": 9223372036854775807, "minimum": -9223372036854775808}, "name": {"title": "Name", "type": "string", "maxLength": 255, "minLength": 1}, "price": {"title": "Price", "type": "number", "x-nullable": true}, "description": {"title": "Description", "type": "string", "maxLength": 200}}}, "ShoppingCart": {"required": ["redirect_url"], "type": "object", "properties": {"redirect_url": {"title": "Redirect url", "type": "string", "maxLength": 256, "minLength": 1}}}, "Notification": {"required": ["title", "body"], "type": "object", "properties": {"title": {"title": "Title", "type": "string", "maxLength": 512, "minLength": 1}, "body": {"title": "Body", "type": "string", "maxLength": 2048, "minLength": 1}, "schedule": {"title": "Schedule", "description": "date and time to send notification", "type": "string", "format": "date-time", "x-nullable": true}, "link": {"title": "Link", "type": "string", "maxLength": 1024}}}, "NotificationForProfiles": {"required": ["title", "body", "profiles"], "type": "object", "properties": {"title": {"title": "Title", "type": "string", "maxLength": 512, "minLength": 1}, "body": {"title": "Body", "type": "string", "maxLength": 2048, "minLength": 1}, "schedule": {"title": "Schedule", "description": "date and time to send notification", "type": "string", "format": "date-time", "x-nullable": true}, "link": {"title": "Link", "type": "string", "maxLength": 1024}, "profiles": {"type": "array", "items": {"description": "The profiles to send the push notification to", "type": "string", "format": "uuid"}}}}, "ProfileList": {"type": "object", "properties": {"url": {"title": "Url", "type": "string", "format": "uri", "readOnly": true}, "public_id": {"title": "Public id", "type": "string", "format": "uuid", "readOnly": true}, "name": {"title": "Name", "type": "string", "readOnly": true, "minLength": 1}, "gender": {"title": "Gender", "type": "string", "enum": ["M", "F", "X"]}, "teams": {"description": "Team of which this profile is a member of", "type": "array", "items": {"$ref": "#/definitions/TeamProfile"}, "readOnly": true}, "reference": {"title": "Reference", "type": "string", "maxLength": 255}, "avatar": {"title": "Avatar", "type": "string", "format": "uri", "minLength": 1, "x-nullable": true}}}, "ProfileCreated": {"type": "object", "properties": {"url": {"title": "Url", "type": "string", "format": "uri", "readOnly": true}, "public_id": {"title": "Public id", "type": "string", "format": "uuid", "readOnly": true}, "given_name": {"title": "Given name", "type": "string", "maxLength": 100}, "family_name": {"title": "Family name", "type": "string", "maxLength": 100}, "nickname": {"title": "Nickname", "type": "string", "maxLength": 100}, "gender": {"title": "Gender", "type": "string", "enum": ["M", "F", "X"]}, "birthdate": {"title": "Birthdate", "type": "string", "format": "date", "x-nullable": true}, "zoneinfo": {"title": "Zoneinfo", "type": "string", "readOnly": true}, "locale": {"title": "Locale", "type": "string", "maxLength": 5}, "reference": {"title": "Reference", "type": "string", "maxLength": 255}, "avatar": {"title": "Avatar", "type": "string", "format": "uri", "minLength": 1, "x-nullable": true}, "bearer": {"title": "Bearer", "description": "Used for authenticating as a profile. Make this the active Authorization bearer to perform actions using this profile.", "type": "string", "readOnly": true, "minLength": 1}}}, "Activity": {"required": ["timestamp", "source", "type"], "type": "object", "properties": {"timestamp": {"title": "Timestamp", "description": "Starting UTC time of the measurement.", "type": "string", "format": "date-time"}, "duration": {"title": "Duration", "description": "Duration of the measurement.", "type": "string", "x-nullable": true}, "source": {"title": "Source", "description": "Origin of the data.", "type": "string", "enum": ["AGGREGATED", "ANDROID", "APPLE", "FITBIT", "GARMIN", "GOOGLE_HEALTH", "GOOGLEFIT", "HEALTHCONNECT", "HUAWEI", "MYZONE", "OMH", "OMRON", "OURA", "POLAR", "SAMSUNG", "STRAVA", "SUUNTO", "WF", "WHOOP", "WITHINGS"]}, "is_manual": {"title": "Is_manual", "description": "Whether the data was entered manually.", "type": "boolean", "x-nullable": true}, "type": {"title": "Type", "description": "Type of the activity.", "type": "string", "enum": ["RUNNING", "CROSSFIT", "CYCLING", "SWIMMING", "OTHER", "ROWING", "WALKING", "MINDFULNESS", "YOGA", "STRENGTH_TRAINING"]}, "distance": {"title": "Distance", "description": "Distance in meters.", "type": "number", "x-nullable": true}, "steps": {"title": "Steps", "description": "Steps taken.", "type": "number", "x-nullable": true}, "elevation": {"title": "Elevation", "description": "Elevation gained during the workout.", "type": "number", "x-nullable": true}, "speed": {"title": "Speed", "description": "Average speed during the workout", "type": "number", "x-nullable": true}, "calories": {"title": "Calories", "description": "Calories burned.", "type": "number", "x-nullable": true}, "points": {"title": "Points", "description": "Points earned.", "type": "number", "x-nullable": true}, "in_outdoor": {"title": "In_outdoor", "description": "in- or outdoor-activity.", "type": "string", "x-nullable": true}}}, "BioMetric": {"required": ["timestamp", "source"], "type": "object", "properties": {"timestamp": {"title": "Timestamp", "description": "Starting UTC time of the measurement.", "type": "string", "format": "date-time"}, "source": {"title": "Source", "description": "Origin of the data.", "type": "string", "enum": ["AGGREGATED", "ANDROID", "APPLE", "FITBIT", "GARMIN", "GOOGLE_HEALTH", "GOOGLEFIT", "HEALTHCONNECT", "HUAWEI", "MYZONE", "OMH", "OMRON", "OURA", "POLAR", "SAMSUNG", "STRAVA", "SUUNTO", "WF", "WHOOP", "WITHINGS"]}, "is_manual": {"title": "Is_manual", "description": "Whether the data was entered manually.", "type": "boolean", "x-nullable": true}, "weight": {"title": "Weight", "description": "Weight in kg.", "type": "number", "x-nullable": true}, "height": {"title": "Height", "description": "Height in cm.", "type": "number", "x-nullable": true}, "bmi": {"title": "Bmi", "description": "Body Mass Index, automatically calculated if not entered and both weight and height are available.", "type": "number", "x-nullable": true}}}, "BiometricMeasurement": {"required": ["timestamp", "source", "measurement_type"], "type": "object", "properties": {"timestamp": {"title": "Timestamp", "description": "Starting time of the measurement.", "type": "string", "format": "date-time"}, "end": {"title": "End", "description": "End time of the measurement.", "type": "string", "format": "date-time", "x-nullable": true}, "source": {"title": "Source", "description": "Origin of the data.", "type": "string", "enum": ["AGGREGATED", "ANDROID", "APPLE", "FITBIT", "GARMIN", "GOOGLE_HEALTH", "GOOGLEFIT", "HEALTHCONNECT", "HUAWEI", "MYZONE", "OMH", "OMRON", "OURA", "POLAR", "SAMSUNG", "STRAVA", "SUUNTO", "WF", "WHOOP", "WITHINGS"]}, "measurement_type": {"title": "Measurement_type", "description": "Type of biometric measurement.", "type": "string", "minLength": 1}, "description": {"title": "Description", "description": "Custom description of biometric measurement", "type": "string", "x-nullable": true}, "is_manual": {"title": "Is_manual", "description": "Whether the data was entered manually.", "type": "boolean", "x-nullable": true}, "value": {"title": "Value", "description": "Value of this measurement.", "type": "number", "x-nullable": true}, "unit": {"title": "Unit", "description": "Unit of this measurement", "type": "string", "x-nullable": true}}}, "BMI": {"required": ["timestamp", "source"], "type": "object", "properties": {"timestamp": {"title": "Timestamp", "description": "Starting UTC time of the measurement.", "type": "string", "format": "date-time"}, "source": {"title": "Source", "description": "Origin of the data.", "type": "string", "enum": ["AGGREGATED", "ANDROID", "APPLE", "FITBIT", "GARMIN", "GOOGLE_HEALTH", "GOOGLEFIT", "HEALTHCONNECT", "HUAWEI", "MYZONE", "OMH", "OMRON", "OURA", "POLAR", "SAMSUNG", "STRAVA", "SUUNTO", "WF", "WHOOP", "WITHINGS"]}, "is_manual": {"title": "Is_manual", "description": "Whether the data was entered manually.", "type": "boolean", "x-nullable": true}, "bmi": {"title": "Bmi", "description": "Body Mass Index, automatically calculated if not entered and both weight and height are available.", "type": "number", "x-nullable": true}}}, "DailyDetail": {"required": ["timestamp", "source"], "type": "object", "properties": {"timestamp": {"title": "Timestamp", "description": "Starting UTC time of the measurement.", "type": "string", "format": "date-time"}, "duration": {"title": "Duration", "description": "Duration of the measurement.", "type": "string", "x-nullable": true}, "source": {"title": "Source", "description": "Origin of the data.", "type": "string", "enum": ["AGGREGATED", "ANDROID", "APPLE", "FITBIT", "GARMIN", "GOOGLE_HEALTH", "GOOGLEFIT", "HEALTHCONNECT", "HUAWEI", "MYZONE", "OMH", "OMRON", "OURA", "POLAR", "SAMSUNG", "STRAVA", "SUUNTO", "WF", "WHOOP", "WITHINGS"]}, "steps": {"title": "Steps", "description": "Steps taken.", "type": "integer", "x-nullable": true}, "calories": {"title": "Calories", "description": "Calories burned.", "type": "number", "x-nullable": true}, "distance": {"title": "Distance", "description": "Distance in meters.", "type": "number", "x-nullable": true}}}, "DailySummary": {"required": ["date", "source"], "type": "object", "properties": {"date": {"title": "Date", "description": "Date of the summary.", "type": "string", "format": "date"}, "distance": {"title": "Distance", "description": "Distance in meters.", "type": "number", "x-nullable": true}, "steps": {"title": "Steps", "description": "Steps taken.", "type": "number", "x-nullable": true}, "calories": {"title": "Calories", "description": "Calories burned.", "type": "number", "x-nullable": true}, "active_calories": {"title": "Active_calories", "description": "Active calorie burn.", "type": "number", "x-nullable": true}, "bmr_calories": {"title": "Bmr_calories", "description": "BMR calorie burn.", "type": "number", "x-nullable": true}, "points": {"title": "Points", "description": "Points earned.", "type": "number", "x-nullable": true}, "source": {"title": "Source", "description": "Origin of the data.", "type": "string", "enum": ["AGGREGATED", "ANDROID", "APPLE", "FITBIT", "GARMIN", "GOOGLE_HEALTH", "GOOGLEFIT", "HEALTHCONNECT", "HUAWEI", "MYZONE", "OMH", "OMRON", "OURA", "POLAR", "SAMSUNG", "STRAVA", "SUUNTO", "WF", "WHOOP", "WITHINGS"]}}}, "DetailSample": {"required": ["timestamp", "source"], "type": "object", "properties": {"timestamp": {"title": "Timestamp", "description": "Starting UTC time of the measurement.", "type": "string", "format": "date-time"}, "duration": {"title": "Duration", "description": "Duration of the measurement.", "type": "string", "x-nullable": true}, "source": {"title": "Source", "description": "Origin of the data.", "type": "string", "enum": ["AGGREGATED", "ANDROID", "APPLE", "FITBIT", "GARMIN", "GOOGLE_HEALTH", "GOOGLEFIT", "HEALTHCONNECT", "HUAWEI", "MYZONE", "OMH", "OMRON", "OURA", "POLAR", "SAMSUNG", "STRAVA", "SUUNTO", "WF", "WHOOP", "WITHINGS"]}, "activity_type": {"title": "Activity_type", "type": "string", "x-nullable": true}, "activity_id": {"title": "Activity_id", "type": "string", "x-nullable": true}, "distance": {"title": "Distance", "type": "number", "x-nullable": true}, "calories": {"title": "Calories", "type": "number", "x-nullable": true}, "heart_rate": {"title": "Heart_rate", "type": "number", "x-nullable": true}}}, "ECGRecordings": {"required": ["timestamp", "source"], "type": "object", "properties": {"timestamp": {"title": "Timestamp", "description": "Starting UTC time of the measurement.", "type": "string", "format": "date-time"}, "duration": {"title": "Duration", "description": "Duration of the measurement.", "type": "string", "x-nullable": true}, "source": {"title": "Source", "description": "Origin of the data.", "type": "string", "enum": ["AGGREGATED", "ANDROID", "APPLE", "FITBIT", "GARMIN", "GOOGLE_HEALTH", "GOOGLEFIT", "HEALTHCONNECT", "HUAWEI", "MYZONE", "OMH", "OMRON", "OURA", "POLAR", "SAMSUNG", "STRAVA", "SUUNTO", "WF", "WHOOP", "WITHINGS"]}, "sample_frequency": {"title": "Sample_frequency", "description": "Sampling frequency of heart beats as integer in Hz.", "type": "integer", "x-nullable": true}, "sample_count": {"title": "Sample_count", "description": "Sample count of heart beats as integer.", "type": "integer", "x-nullable": true}}}, "ECGRecording": {"required": ["timestamp", "source"], "type": "object", "properties": {"timestamp": {"title": "Timestamp", "description": "Starting UTC time of the measurement.", "type": "string", "format": "date-time"}, "duration": {"title": "Duration", "description": "Duration of the measurement.", "type": "string", "x-nullable": true}, "source": {"title": "Source", "description": "Origin of the data.", "type": "string", "enum": ["AGGREGATED", "ANDROID", "APPLE", "FITBIT", "GARMIN", "GOOGLE_HEALTH", "GOOGLEFIT", "HEALTHCONNECT", "HUAWEI", "MYZONE", "OMH", "OMRON", "OURA", "POLAR", "SAMSUNG", "STRAVA", "SUUNTO", "WF", "WHOOP", "WITHINGS"]}, "sample_frequency": {"title": "Sample_frequency", "description": "Sampling frequency of heart beats as integer in Hz.", "type": "integer", "x-nullable": true}, "sample_count": {"title": "Sample_count", "description": "Sample count of heart beats as integer.", "type": "integer", "x-nullable": true}, "data": {"description": "ECG data, represented as [[time (s), value (mcV)], [time2 (s), value2 (mcV)]), ..", "type": "array", "items": {"type": "string", "x-nullable": true}, "x-nullable": true}}}, "Event": {"type": "object", "properties": {"timestamp": {"title": "Timestamp", "description": "Time at which the action was performed.", "type": "string", "format": "date-time"}, "points": {"title": "Points", "description": "Amount of points awarded for the action.", "type": "number", "x-nullable": true}, "description": {"title": "Description", "description": "Title / description of the action.", "type": "string", "x-nullable": true}}}, "HeartRateSample": {"required": ["timestamp", "source"], "type": "object", "properties": {"timestamp": {"title": "Timestamp", "description": "Starting UTC time of the measurement.", "type": "string", "format": "date-time"}, "duration": {"title": "Duration", "description": "Duration of the measurement.", "type": "string", "x-nullable": true}, "source": {"title": "Source", "description": "Origin of the data.", "type": "string", "enum": ["AGGREGATED", "ANDROID", "APPLE", "FITBIT", "GARMIN", "GOOGLE_HEALTH", "GOOGLEFIT", "HEALTHCONNECT", "HUAWEI", "MYZONE", "OMH", "OMRON", "OURA", "POLAR", "SAMSUNG", "STRAVA", "SUUNTO", "WF", "WHOOP", "WITHINGS"]}, "is_manual": {"title": "Is_manual", "description": "Whether the data was entered manually.", "type": "boolean", "x-nullable": true}, "value": {"title": "Value", "description": "Measured heart rate in beats/min.", "type": "integer", "x-nullable": true}, "min": {"title": "Min", "description": "Minimum value measured in the time window.", "type": "integer", "x-nullable": true}, "max": {"title": "Max", "description": "Maximum value measured in the time window.", "type": "integer", "x-nullable": true}}}, "HeartRateSummary": {"required": ["timestamp", "source"], "type": "object", "properties": {"timestamp": {"title": "Timestamp", "description": "Starting UTC time of the measurement.", "type": "string", "format": "date-time"}, "duration": {"title": "Duration", "description": "Duration of the measurement.", "type": "string", "x-nullable": true}, "source": {"title": "Source", "description": "Origin of the data.", "type": "string", "enum": ["AGGREGATED", "ANDROID", "APPLE", "FITBIT", "GARMIN", "GOOGLE_HEALTH", "GOOGLEFIT", "HEALTHCONNECT", "HUAWEI", "MYZONE", "OMH", "OMRON", "OURA", "POLAR", "SAMSUNG", "STRAVA", "SUUNTO", "WF", "WHOOP", "WITHINGS"]}, "is_manual": {"title": "Is_manual", "description": "Whether the data was entered manually.", "type": "boolean", "x-nullable": true}, "min": {"title": "Min", "description": "Minimum heart rate.", "type": "integer", "x-nullable": true}, "max": {"title": "Max", "description": "Maximum heart rate.", "type": "integer", "x-nullable": true}, "average": {"title": "Average", "description": "Average heart rate.", "type": "integer", "x-nullable": true}, "resting": {"title": "Resting", "description": "Resting heart rate.", "type": "integer", "x-nullable": true}}}, "Height": {"required": ["timestamp", "source"], "type": "object", "properties": {"timestamp": {"title": "Timestamp", "description": "Starting UTC time of the measurement.", "type": "string", "format": "date-time"}, "source": {"title": "Source", "description": "Origin of the data.", "type": "string", "enum": ["AGGREGATED", "ANDROID", "APPLE", "FITBIT", "GARMIN", "GOOGLE_HEALTH", "GOOGLEFIT", "HEALTHCONNECT", "HUAWEI", "MYZONE", "OMH", "OMRON", "OURA", "POLAR", "SAMSUNG", "STRAVA", "SUUNTO", "WF", "WHOOP", "WITHINGS"]}, "is_manual": {"title": "Is_manual", "description": "Whether the data was entered manually.", "type": "boolean", "x-nullable": true}, "height": {"title": "Height", "description": "Height in cm.", "type": "number", "x-nullable": true}}}, "SleepDetail": {"required": ["timestamp", "source", "level"], "type": "object", "properties": {"timestamp": {"title": "Timestamp", "description": "Starting UTC time of the measurement.", "type": "string", "format": "date-time"}, "source": {"title": "Source", "description": "Origin of the data.", "type": "string", "enum": ["AGGREGATED", "ANDROID", "APPLE", "FITBIT", "GARMIN", "GOOGLE_HEALTH", "GOOGLEFIT", "HEALTHCONNECT", "HUAWEI", "MYZONE", "OMH", "OMRON", "OURA", "POLAR", "SAMSUNG", "STRAVA", "SUUNTO", "WF", "WHOOP", "WITHINGS"]}, "timestamp_end": {"title": "Timestamp end", "description": "Ending time of the measurement.", "type": "string", "format": "date-time"}, "level": {"title": "Level", "description": "Sleep level", "type": "string", "enum": ["AWAKE", "LIGHT", "DEEP", "REM", "UNKNOWN"]}}}, "Sample": {"type": "object", "properties": {"value": {"title": "Value", "type": "number / string", "readOnly": true, "x-nullable": true, "description": "Number for hrv and heart_rate, string for movement and sleep_stages"}}}, "SleepSample": {"required": ["timestamp", "source", "data_type"], "type": "object", "properties": {"timestamp": {"title": "Timestamp", "description": "Starting UTC time of the measurement.", "type": "string", "format": "date-time"}, "duration": {"title": "Duration", "description": "Duration of the measurement.", "type": "string", "x-nullable": true}, "source": {"title": "Source", "description": "Origin of the data.", "type": "string", "enum": ["AGGREGATED", "ANDROID", "APPLE", "FITBIT", "GARMIN", "GOOGLE_HEALTH", "GOOGLEFIT", "HEALTHCONNECT", "HUAWEI", "MYZONE", "OMH", "OMRON", "OURA", "POLAR", "SAMSUNG", "STRAVA", "SUUNTO", "WF", "WHOOP", "WITHINGS"]}, "is_manual": {"title": "Is_manual", "description": "Whether the data was entered manually.", "type": "boolean", "x-nullable": true}, "interval": {"title": "Interval", "description": "Interval in seconds", "type": "integer", "x-nullable": true}, "data_type": {"title": "Data type", "description": "Sleep data type", "type": "string", "enum": ["HEART_RATE", "HRV", "MOVEMENT", "SLEEP_STAGES"]}, "samples": {"description": "Sample values", "type": "array", "items": {"$ref": "#/definitions/Sample"}, "readOnly": true}}}, "SleepDetailMinimal": {"required": ["timestamp", "level"], "type": "object", "properties": {"timestamp": {"title": "Timestamp", "description": "Starting UTC time of the measurement.", "type": "string", "format": "date-time"}, "timestamp_end": {"title": "Timestamp end", "description": "Ending time of the measurement.", "type": "string", "format": "date-time"}, "level": {"title": "Level", "description": "Sleep level", "type": "string", "enum": ["AWAKE", "LIGHT", "DEEP", "REM", "UNKNOWN"]}}}, "SleepSummary": {"required": ["timestamp", "source"], "type": "object", "properties": {"timestamp": {"title": "Timestamp", "description": "Starting UTC time of the measurement.", "type": "string", "format": "date-time"}, "duration": {"title": "Duration", "description": "Duration of the measurement.", "type": "string", "x-nullable": true}, "timestamp_end": {"title": "Timestamp end", "type": "string", "format": "date-time"}, "source": {"title": "Source", "description": "Origin of the data.", "type": "string", "enum": ["AGGREGATED", "ANDROID", "APPLE", "FITBIT", "GARMIN", "GOOGLE_HEALTH", "GOOGLEFIT", "HEALTHCONNECT", "HUAWEI", "MYZONE", "OMH", "OMRON", "OURA", "POLAR", "SAMSUNG", "STRAVA", "SUUNTO", "WF", "WHOOP", "WITHINGS"]}, "is_manual": {"title": "Is_manual", "description": "Whether the data was entered manually.", "type": "boolean", "x-nullable": true}, "awake": {"title": "Awake", "description": "Time awake.", "type": "string <iso8601 duration>", "minLength": 1}, "light": {"title": "Light", "description": "Time in light sleep.", "type": "string <iso8601 duration>", "minLength": 1}, "deep": {"title": "Deep", "description": "Time in deep sleep.", "type": "string <iso8601 duration>", "minLength": 1}, "rem": {"title": "Rem", "description": "Time in REM sleep.", "type": "string <iso8601 duration>", "minLength": 1}, "sleep_score": {"title": "Sleep_score", "description": "Sleep score", "type": "integer", "x-nullable": true}, "detail": {"type": "array", "items": {"$ref": "#/definitions/SleepDetailMinimal"}}}}, "StressSample": {"required": ["timestamp", "source", "stress_value"], "type": "object", "properties": {"timestamp": {"title": "Timestamp", "description": "Starting UTC time of the measurement.", "type": "string", "format": "date-time"}, "source": {"title": "Source", "description": "Origin of the data.", "type": "string", "enum": ["AGGREGATED", "ANDROID", "APPLE", "FITBIT", "GARMIN", "GOOGLE_HEALTH", "GOOGLEFIT", "HEALTHCONNECT", "HUAWEI", "MYZONE", "OMH", "OMRON", "OURA", "POLAR", "SAMSUNG", "STRAVA", "SUUNTO", "WF", "WHOOP", "WITHINGS"]}, "stress_value": {"title": "Stress_value", "description": "Stress value.", "type": "integer"}}}, "StressSummary": {"required": ["timestamp", "source", "stress_qualifier"], "type": "object", "properties": {"timestamp": {"title": "Timestamp", "description": "Starting UTC time of the measurement.", "type": "string", "format": "date-time"}, "duration": {"title": "Duration", "description": "Duration of the measurement.", "type": "string", "x-nullable": true}, "source": {"title": "Source", "description": "Origin of the data.", "type": "string", "enum": ["AGGREGATED", "ANDROID", "APPLE", "FITBIT", "GARMIN", "GOOGLE_HEALTH", "GOOGLEFIT", "HEALTHCONNECT", "HUAWEI", "MYZONE", "OMH", "OMRON", "OURA", "POLAR", "SAMSUNG", "STRAVA", "SUUNTO", "WF", "WHOOP", "WITHINGS"]}, "stress_qualifier": {"title": "Stress qualifier", "description": "Qualifier describing stress level.", "type": "string", "enum": ["UNKNOWN", "CALM", "BALANCED", "STRESSFUL", "VERY_STRESSFUL"]}, "average_stress_level": {"title": "Average_stress_level", "description": "Average stress level.", "type": "integer", "x-nullable": true}, "max_stress_level": {"title": "Max_stress_level", "description": "Maximum stress level.", "type": "integer", "x-nullable": true}, "rest_stress_duration": {"title": "Rest stress duration", "description": "Time at restful stress level.", "type": "string <iso8601 duration>", "minLength": 1}, "low_stress_duration": {"title": "Low stress duration", "description": "Time at low stress level.", "type": "string <iso8601 duration>", "minLength": 1}, "medium_stress_duration": {"title": "Medium stress duration", "description": "Time at medium stress level.", "type": "string <iso8601 duration>", "minLength": 1}, "high_stress_duration": {"title": "High stress duration", "description": "Time at high stress level.", "type": "string <iso8601 duration>", "minLength": 1}, "stress_duration": {"title": "Stress duration", "description": "Total time in stress.", "type": "string <iso8601 duration>", "minLength": 1}}}, "TrackSample": {"required": ["timestamp", "source"], "type": "object", "properties": {"timestamp": {"title": "Timestamp", "description": "Starting UTC time of the measurement.", "type": "string", "format": "date-time"}, "duration": {"title": "Duration", "description": "Duration of the measurement.", "type": "string", "x-nullable": true}, "source": {"title": "Source", "description": "Origin of the data.", "type": "string", "enum": ["AGGREGATED", "ANDROID", "APPLE", "FITBIT", "GARMIN", "GOOGLE_HEALTH", "GOOGLEFIT", "HEALTHCONNECT", "HUAWEI", "MYZONE", "OMH", "OMRON", "OURA", "POLAR", "SAMSUNG", "STRAVA", "SUUNTO", "WF", "WHOOP", "WITHINGS"]}, "activity_type": {"title": "Activity_type", "type": "string", "x-nullable": true}, "activity_id": {"title": "Activity_id", "type": "string", "x-nullable": true}, "distance": {"title": "Distance", "type": "number", "x-nullable": true}, "calories": {"title": "Calories", "type": "number", "x-nullable": true}}}, "Weight": {"required": ["timestamp", "source"], "type": "object", "properties": {"timestamp": {"title": "Timestamp", "description": "Starting UTC time of the measurement.", "type": "string", "format": "date-time"}, "source": {"title": "Source", "description": "Origin of the data.", "type": "string", "enum": ["AGGREGATED", "ANDROID", "APPLE", "FITBIT", "GARMIN", "GOOGLE_HEALTH", "GOOGLEFIT", "HEALTHCONNECT", "HUAWEI", "MYZONE", "OMH", "OMRON", "OURA", "POLAR", "SAMSUNG", "STRAVA", "SUUNTO", "WF", "WHOOP", "WITHINGS"]}, "is_manual": {"title": "Is_manual", "description": "Whether the data was entered manually.", "type": "boolean", "x-nullable": true}, "weight": {"title": "Weight", "description": "Weight in kg.", "type": "number", "x-nullable": true}}}, "Workout": {"required": ["timestamp", "source", "type"], "type": "object", "properties": {"timestamp": {"title": "Timestamp", "description": "Starting UTC time of the measurement.", "type": "string", "format": "date-time"}, "duration": {"title": "Duration", "description": "Duration of the measurement.", "type": "string", "x-nullable": true}, "source": {"title": "Source", "description": "Origin of the data.", "type": "string", "enum": ["AGGREGATED", "ANDROID", "APPLE", "FITBIT", "GARMIN", "GOOGLE_HEALTH", "GOOGLEFIT", "HEALTHCONNECT", "HUAWEI", "MYZONE", "OMH", "OMRON", "OURA", "POLAR", "SAMSUNG", "STRAVA", "SUUNTO", "WF", "WHOOP", "WITHINGS"]}, "is_manual": {"title": "Is_manual", "description": "Whether the data was entered manually.", "type": "boolean", "x-nullable": true}, "type": {"title": "Type", "description": "Type of the activity.", "type": "string", "enum": ["RUNNING", "CROSSFIT", "CYCLING", "SWIMMING", "OTHER", "ROWING", "WALKING", "MINDFULNESS", "YOGA", "STRENGTH_TRAINING"]}, "distance": {"title": "Distance", "description": "Distance in meters.", "type": "number", "x-nullable": true}, "steps": {"title": "Steps", "description": "Steps taken.", "type": "number", "x-nullable": true}, "elevation": {"title": "Elevation", "description": "Elevation gained during the workout.", "type": "number", "x-nullable": true}, "speed": {"title": "Speed", "description": "Average speed during the workout", "type": "number", "x-nullable": true}, "calories": {"title": "Calories", "description": "Calories burned.", "type": "number", "x-nullable": true}, "points": {"title": "Points", "description": "Points earned.", "type": "number", "x-nullable": true}, "in_outdoor": {"title": "In_outdoor", "description": "in- or outdoor-activity.", "type": "string", "x-nullable": true}}}, "ProfileDetail": {"type": "object", "properties": {"url": {"title": "Url", "type": "string", "format": "uri", "readOnly": true}, "public_id": {"title": "Public id", "type": "string", "format": "uuid", "readOnly": true}, "given_name": {"title": "Given name", "type": "string", "maxLength": 100}, "family_name": {"title": "Family name", "type": "string", "maxLength": 100}, "nickname": {"title": "Nickname", "type": "string", "maxLength": 100}, "gender": {"title": "Gender", "type": "string", "enum": ["M", "F", "X"]}, "birthdate": {"title": "Birthdate", "type": "string", "format": "date", "x-nullable": true}, "zoneinfo": {"title": "Zoneinfo", "type": "string", "readOnly": true}, "locale": {"title": "Locale", "type": "string", "maxLength": 5}, "total_calories": {"title": "Total calories", "type": "number"}, "total_distance": {"title": "Total distance", "type": "number"}, "total_steps": {"title": "Total steps", "type": "number"}, "total_points": {"title": "Total points", "type": "number"}, "total_activity_duration": {"title": "Total activity duration", "type": "string <iso8601 duration>", "readOnly": true, "minLength": 1}, "reference": {"title": "Reference", "type": "string", "maxLength": 255}, "teams": {"description": "Team of which this profile is a member of", "type": "array", "items": {"$ref": "#/definitions/TeamProfile"}, "readOnly": true}, "avatar": {"title": "Avatar", "type": "string", "format": "uri", "minLength": 1, "x-nullable": true}, "created_at": {"title": "Created at", "type": "string", "format": "date-time", "readOnly": true}, "updated_at": {"title": "Updated at", "type": "string", "format": "date-time", "readOnly": true}}}, "EnrollmentInformation": {"type": "object", "properties": {"team": {"title": "Team", "type": "string", "readOnly": true, "minLength": 1}, "team_public_id": {"title": "Team public id", "type": "string", "readOnly": true, "minLength": 1}, "team_size": {"title": "Team size", "type": "integer", "readOnly": true}, "leaderboard_rank": {"title": "Leaderboard rank", "description": "Current or final rank among the participants of the challenge as determined by the relevant score.", "type": "integer", "readOnly": true}, "leaderboard_score": {"title": "Leaderboard score", "description": "The profile's current or final score.", "type": "number", "readOnly": true}}}, "ProfileChallengeList": {"required": ["title", "start", "type", "goal", "goal_type", "visibility"], "type": "object", "properties": {"url": {"title": "Url", "type": "string", "format": "uri", "readOnly": true}, "public_id": {"title": "Public id", "type": "string", "format": "uuid", "readOnly": true}, "title": {"title": "Title", "type": "string", "minLength": 1}, "slogan": {"title": "Slogan", "type": "string"}, "description": {"title": "Description", "type": "string"}, "start": {"title": "Start", "type": "string", "format": "date-time"}, "end": {"title": "End", "type": "string", "format": "date-time", "x-nullable": true}, "type": {"title": "Type", "type": "string", "enum": ["INDIVIDUAL", "GROUP", "TEAM"]}, "goal": {"title": "Goal", "type": "string", "enum": ["DAILY", "TOTAL", "WEEKLY", "MONTHLY"]}, "goal_value": {"title": "Goal value", "type": "integer", "maximum": 2147483647, "minimum": -2147483648, "x-nullable": true}, "goal_type": {"title": "Goal type", "type": "string", "enum": ["POINTS", "DISTANCE", "CALORIES", "DURATION", "STEPS"]}, "visibility": {"title": "Visibility", "type": "string", "enum": ["PUBLIC", "PRIVATE"]}, "num_members": {"title": "Num members", "type": "string", "readOnly": true}, "leaderboard_rank": {"title": "Leaderboard rank", "description": "Current or final rank among the participants of the challenge as determined by the relevant score.", "type": "integer", "readOnly": true}, "leaderboard_score": {"title": "Leaderboard score", "description": "The profile's current or final score.", "type": "number", "readOnly": true}, "is_participating": {"title": "Is participating", "description": "Does the current profile participate in this challenge?", "type": "boolean", "readOnly": true}, "enrollment": {"$ref": "#/definitions/EnrollmentInformation"}}}, "ProfileAppConnectionList": {"type": "object", "properties": {"display_name": {"title": "Display name", "type": "string", "readOnly": true}, "url": {"title": "Url", "type": "string", "readOnly": true, "minLength": 1}, "connected": {"title": "Connected", "type": "boolean", "readOnly": true}, "connection_slug": {"title": "Connection slug", "type": "string", "readOnly": true, "minLength": 1}, "img_url": {"title": "Img url", "type": "string", "readOnly": true, "minLength": 1}, "created_at": {"title": "Created at", "type": "string", "format": "date-time", "readOnly": true}, "updated_at": {"title": "Updated at", "type": "string", "format": "date-time", "readOnly": true}}}, "TeamList": {"required": ["name"], "type": "object", "properties": {"name": {"title": "Name", "type": "string", "maxLength": 100, "minLength": 1}, "public_id": {"title": "Public id", "type": "string", "format": "uuid", "readOnly": true}, "url": {"title": "Url", "type": "string", "format": "uri", "readOnly": true}, "num_members": {"title": "Num members", "type": "string", "readOnly": true}, "avatar": {"title": "Avatar", "type": "string", "format": "uri", "minLength": 1, "x-nullable": true}}}, "ProfileTeam": {"description": "List of members in this team", "type": "object", "properties": {"url": {"title": "Url", "type": "string", "format": "uri", "readOnly": true}, "public_id": {"title": "Public id", "type": "string", "format": "uuid", "readOnly": true}, "name": {"title": "Name", "type": "string", "readOnly": true, "minLength": 1}, "reference": {"title": "Reference", "type": "string", "maxLength": 255}}}, "TeamDetail": {"required": ["name"], "type": "object", "properties": {"name": {"title": "Name", "type": "string", "maxLength": 100, "minLength": 1}, "public_id": {"title": "Public id", "type": "string", "format": "uuid", "readOnly": true}, "url": {"title": "Url", "type": "string", "format": "uri", "readOnly": true}, "num_members": {"title": "Num members", "type": "string", "readOnly": true}, "members": {"description": "List of members in this team", "type": "array", "items": {"$ref": "#/definitions/ProfileTeam"}, "readOnly": true}, "avatar": {"title": "Avatar", "type": "string", "format": "uri", "minLength": 1, "x-nullable": true}}}, "ProfilePublicIdsList": {"required": ["profiles"], "type": "object", "properties": {"profiles": {"type": "array", "items": {"type": "string", "format": "uuid"}}, "is_active": {"title": "Is active", "description": "Whether profile actively participates in challenge.\n\nWhile inactive, scores/leaderboard will not be updated but still be visible.", "type": "boolean"}}}, "Token": {"type": "object", "properties": {"bearer": {"title": "Bearer", "type": "string", "readOnly": true, "minLength": 1}}}}, "tags": [{"name": "profile", "description": "\nProfiles are containers for wearables data.\nThe profiles can be seen as an extension of users in a different system.\nProfiles are anonymous objects which can participate in teams and challenges.\n\nKeep in mind, listing profiles and creating profiles need an administrative bearer token, all profile specific actions\nneed a seperate bearer token that is returned after creating a profile. This bearer token is used in place of the\nadministrative bearer token. (see profile create action for more information)\n"}, {"name": "challenge", "description": "\nWeFitter API’s challenge engine will bring endless engagement to your platform.\nFor more information about the possibilities in challenges please go to https://www.wefitter.com/en-us/features/gamification/\n\nChallenges have multilanguage support on the fields: `Title`, `Slogan`, and `Description`.\nBy default, challenges get the default-language that is configured in the app. Whenever a challenge is requested through the API this challenge will be presented in the default language.\nIf another language is preferred, this can be requested by adding the header parameter `Accept-Language` stating the language short code (ex. `en` for english). If this language short code is not present in the title of the challenge, the default language will be returned.\n\nThese translation fields contain JSON strings, for example:\n```{\"en\":\"this is the English title\",\"nl\":\"this is the Dutch title\"}```\nSo to create a multilanguage challenge, please provide the title, slogan, and description field as json strings, be aware that because of serialization this should be formed with backward slashes:\n\n\n<table><tbody>\n    <tr><td>\n{\n\n\"title\": \"{\\\"en\\\":\\\"this is the English title\\\", \\\"nl\\\":\\\"this is the dutch title\\\"}\",\n\n\"slogan\": \"{\\\"en\\\":\\\"this is the English title\\\", \\\"nl\\\":\\\"this is the dutch slogan\\\"}\",\n\n\"description\": \"{\\\"en\\\":\\\"this is the English title\\\", \\\"nl\\\":\\\"this is the dutch description\\\"}\",\n\n}\n</td></tr>\n</tbody></table>\n\n"}, {"name": "connection", "description": "Connections are the links between profiles and their wearables."}, {"name": "token", "description": "\n<p>\nBefore any calls can be made to wefitter, BasicAuth is needed to verify the identity of the requesting party.\nThis call will result into a Bearer token which has administrator privileges and is valid for 1 day.\nThis token can be used to create profiles, challenges, etc.\n</p>\n\n<p>\nThe returned bearer is a JWT (<a href=\"https://en.wikipedia.org/wiki/JSON_Web_Token\">JSON Web Token</a>).\n</p>\n"}, {"name": "notification", "description": "Send a notification to all devices for the specified profiles\nThe data will be sent to the client in the following format:\n```\n{\n        \"app\": <app public id>,\n        \"title\": <title>,\n        \"body\": <body>,\n        \"link\": <optional link>\n}\n```\n"}]}