Register (public)

POST /auth/register

Register a new ambassador

Headers

  • X-Popsell-Domain string Required

    The domain of the user

application/json

Body

  • key_data string(nullable)
  • customer_id string
  • broker_id string(nullable)
  • supervisor_identity string(nullable)
  • ambassador_id_referrer string(nullable)
  • id_ws string(nullable)
  • id_ws_referrer string(nullable)
  • image string(nullable)
  • gender string
  • firstname string Required
  • lastname string Required
  • username string(nullable)
  • description string
  • motivation_letter string(nullable)
  • email string(email) Required
  • dob string(nullable)
  • lang string
  • store_id string(nullable)
  • phone_1 string
  • phone_2 string
  • fb_account string(nullable)
  • twitter_account string(nullable)
  • instagram_account string(nullable)
  • linkedIn_account string(nullable)
  • youtube_account string(nullable)
  • password string Required
  • roles array[object]
    Hide roles attribute Show roles attribute object
    • status_role string
  • address array[object]
    Hide address attributes Show address attributes object
    • latitude string
    • longitude string
    • city string
    • postcode string
    • country string
    • street string
    • street2 string

Responses

  • 201 application/json

    Return the complete ambassador

    Hide response attributes Show response attributes object
    • id_ambassador integer(int32)
    • id_brand integer(int32)
    • date_insert string
    • date_update string
    • key_data string(nullable)
    • customer_id string
    • broker_id string(nullable)
    • shopify_customer_id string(nullable)
    • facebook_id string
    • google_id string(nullable)
    • apple_id string(nullable)
    • supervisor_identity string(nullable)
    • ambassador_id_referrer string(nullable)
    • id_ws string(nullable)
    • id_ws_referrer string(nullable)
    • image string(nullable)
    • gender string
    • firstname string
    • lastname string
    • username string(nullable)
    • description string
    • motivation_letter string(nullable)
    • email string
    • email_tmp string(nullable)
    • dob string(nullable)
    • lang string
    • phone_1 string
    • phone_2 string
    • email_notification_enabled boolean
    • gamification_score integer
    • gamification_current_level integer(nullable)
    • gamification_next_level integer(nullable)
    • gamification_level_badge string(nullable)
    • gamification_level_label string(nullable)
    • gamification_id_level string(nullable)
    • gamification_current_level_value integer
    • gamification_points integer(bigint)
    • last_date_gamification string(nullable)
    • optin_cgu boolean
    • optin_cgu_photos boolean
    • active boolean
    • status integer(int32)
    • unsubscribe string(nullable)
    • last_date_connection string(nullable)
    • activation_date string(nullable)
    • validate_date string(nullable)
    • availability string(nullable)
    • unavailable boolean
    • last_action_date string(nullable)
    • is_absent boolean
    • absent_msg string(nullable)
    • fb_account string(nullable)
    • twitter_account string(nullable)
    • instagram_account string(nullable)
    • linkedIn_account string(nullable)
    • youtube_account string(nullable)
    • register_src string(nullable)
    • register_landing_url string(nullable)
    • onboarding_sequence string(nullable)
    • social_community_display boolean
    • last_contact_import string(nullable)
    • sell_token_amount string(nullable)
    • products_purchased_limit string(nullable)
    • nb_public_popliste string(nullable)
    • nb_private_popliste string(nullable)
    • chat_topics array[integer]
    • status_role string
    • manager_role string
    • ids_guest_accounts array[integer]
  • 401 application/json

    Unauthorized.

    Hide response attribute Show response attribute object
    • message string
  • 422 application/json

    Unprocessable Content

    Hide response attributes Show response attributes object
    • message string

      Error message.

    • errors object
      Hide errors attributes Show errors attributes object
      • field array[string]

        Error message details.

      • * array[string] Additional properties

        Error message details.

POST /auth/register
curl \
 --request POST 'https://domain.tld/api/v2/auth/register' \
 --header "Content-Type: application/json" \
 --header "X-Popsell-Domain: example.com" \
 --data '{"key_data":"string","customer_id":"string","broker_id":"string","supervisor_identity":"string","ambassador_id_referrer":"string","id_ws":"string","id_ws_referrer":"string","image":"string","gender":"string","firstname":"string","lastname":"string","username":"string","description":"string","motivation_letter":"string","email":"hello@example.com","dob":"string","lang":"string","store_id":"string","phone_1":"string","phone_2":"string","fb_account":"string","twitter_account":"string","instagram_account":"string","linkedIn_account":"string","youtube_account":"string","password":"string","roles":[{"status_role":"string"}],"address":[{"latitude":"string","longitude":"string","city":"string","postcode":"string","country":"string","street":"string","street2":"string"}]}'
Request examples
# Headers
X-Popsell-Domain: example.com

# Payload
{
  "key_data": "string",
  "customer_id": "string",
  "broker_id": "string",
  "supervisor_identity": "string",
  "ambassador_id_referrer": "string",
  "id_ws": "string",
  "id_ws_referrer": "string",
  "image": "string",
  "gender": "string",
  "firstname": "string",
  "lastname": "string",
  "username": "string",
  "description": "string",
  "motivation_letter": "string",
  "email": "hello@example.com",
  "dob": "string",
  "lang": "string",
  "store_id": "string",
  "phone_1": "string",
  "phone_2": "string",
  "fb_account": "string",
  "twitter_account": "string",
  "instagram_account": "string",
  "linkedIn_account": "string",
  "youtube_account": "string",
  "password": "string",
  "roles": [
    {
      "status_role": "string"
    }
  ],
  "address": [
    {
      "latitude": "string",
      "longitude": "string",
      "city": "string",
      "postcode": "string",
      "country": "string",
      "street": "string",
      "street2": "string"
    }
  ]
}
Response examples (201)
{
  "id_ambassador": 42,
  "id_brand": 42,
  "date_insert": "string",
  "date_update": "string",
  "key_data": "string",
  "customer_id": "string",
  "broker_id": "string",
  "shopify_customer_id": "string",
  "facebook_id": "string",
  "google_id": "string",
  "apple_id": "string",
  "supervisor_identity": "string",
  "ambassador_id_referrer": "string",
  "id_ws": "string",
  "id_ws_referrer": "string",
  "image": "string",
  "gender": "string",
  "firstname": "string",
  "lastname": "string",
  "username": "string",
  "description": "string",
  "motivation_letter": "string",
  "email": "string",
  "email_tmp": "string",
  "dob": "string",
  "lang": "string",
  "phone_1": "string",
  "phone_2": "string",
  "email_notification_enabled": true,
  "gamification_score": 42,
  "gamification_current_level": 42,
  "gamification_next_level": 42,
  "gamification_level_badge": "string",
  "gamification_level_label": "string",
  "gamification_id_level": "string",
  "gamification_current_level_value": 42,
  "gamification_points": 42,
  "last_date_gamification": "string",
  "optin_cgu": true,
  "optin_cgu_photos": true,
  "active": true,
  "status": 42,
  "unsubscribe": "string",
  "last_date_connection": "string",
  "activation_date": "string",
  "validate_date": "string",
  "availability": "string",
  "unavailable": true,
  "last_action_date": "string",
  "is_absent": true,
  "absent_msg": "string",
  "fb_account": "string",
  "twitter_account": "string",
  "instagram_account": "string",
  "linkedIn_account": "string",
  "youtube_account": "string",
  "register_src": "string",
  "register_landing_url": "string",
  "onboarding_sequence": "string",
  "social_community_display": true,
  "last_contact_import": "string",
  "sell_token_amount": "string",
  "products_purchased_limit": "string",
  "nb_public_popliste": "string",
  "nb_private_popliste": "string",
  "chat_topics": [
    42
  ],
  "status_role": "string",
  "manager_role": "string",
  "ids_guest_accounts": [
    42
  ]
}
Response examples (401)
{
  "message": "Unauthorized."
}
Response examples (422)
{
  "message": "field is required! (and 3 more error)",
  "errors": {
    "field": [
      "Error message details here"
    ],
    "additionalProperty1": [
      "Error message details here"
    ],
    "additionalProperty2": [
      "Error message details here"
    ]
  }
}