Users
User management and profile endpoints. All require authentication unless otherwise noted.
Get current user
GET /api/user
Returns the authenticated user's profile.
Authentication: Required
Example Request
curl -H "Authorization: Bearer YOUR_TOKEN" \
https://fangate.info/api/userResponse (200)
{
"success": true,
"errors_message": null,
"data": {
"id": 1,
"type": "business",
"email": "creator@example.com",
"first_name": "John",
"last_name": "Doe",
"birth_date": "2000-01-30",
"stripe_url": "https://connect.stripe.com/...",
"fee": {
"percentage": 10,
"fixed": 0
},
"iban": "...",
"bic_swift": "...",
"is_adult_content": true,
"is_verif_age": true,
"currency_id": 1
}
}user.resource schema
| Field | Type | Description |
|---|---|---|
id | integer | User ID |
type | string | Account type (e.g. business) |
email | string | Email address |
first_name | string | First name |
last_name | string | Last name |
birth_date | string | Date of birth (YYYY-MM-DD) |
stripe_url | string | Stripe Connect onboarding URL |
fee | object | Platform fee structure |
iban | string | Bank IBAN |
bic_swift | string | Bank BIC/SWIFT |
is_adult_content | boolean | Default AVS flag for uploads |
is_verif_age | boolean | Default Yoti requirement |
currency_id | integer | Preferred currency ID |
Update user
PATCH /api/user/{user_id}
Updates user profile. Note: some fields (e.g. personal info, bank details) may be view-only. Creators can typically edit default AVS and age check settings.
Authentication: Required
Request Body
| Field | Type | Description |
|---|---|---|
is_adult_content | boolean | Default AVS setting |
is_verif_age | boolean | Default Yoti requirement |
Response (200)
{
"success": true,
"errors_message": null,
"data": { "user": { ... } }
}Update profile (adult content defaults)
PATCH /api/user/profile/has-adult
Updates the creator's default adult content and age verification settings.
Authentication: Required
Request Body
| Field | Type | Description |
|---|---|---|
is_adult_content | boolean | Default AVS flag |
is_verif_age | boolean | Default Yoti requirement |
Response (200)
{
"success": true,
"errors_message": null,
"data": { "user": { ... } }
}Delete user account
DELETE /api/user
Permanently deletes the authenticated user's account. GDPR compliant.
Authentication: Required
Response (200)
{
"success": true,
"errors_message": null,
"data": "Account deleted"
}FCM tokens
Store FCM token
POST /api/user/fcm
Stores the device's FCM (Firebase Cloud Messaging) token for push notifications.
Authentication: Required
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
token | string | Yes | FCM token |
Response (200)
{
"success": true,
"errors_message": null,
"data": "Token stored"
}Delete FCM token
DELETE /api/user/fcm
Removes the FCM token. Pass the token in the request body or as configured.
Authentication: Required
Response (200)
{
"success": true,
"errors_message": null,
"data": "Token removed"
}