Aller au contenu

Inscrire le membre connecté à un événement

POST
/v1/events/{slug}/registrations
curl --request POST \
--url https://api.vimine.network/v1/events/example/registrations \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "registration_type": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "note": "example", "quantity": 1, "locale": "example" }'

Type gratuit : 201 avec status: confirmed et le token du QR. Type payant : 201 avec status: reserved, le montant et les payment_instructions de l’association ; l’inscription est confirmée quand l’association enregistre la contribution (Stripe Checkout arrive avec la phase L3). 422 not_eligible porte les raisons (voir l’éligibilité).

slug
obligatoire
string
Type de médiaapplication/json
object
registration_type
obligatoire
string format : uuid
note
string
nullable <= 2000 caractères
quantity
integer
>= 1
locale

La langue dans laquelle l’inscription a été faite (it, en) : la langue des e-mails à un invité, et la langue de repli pour un membre qui n’en a jamais choisi. Par défaut : Accept-Language

string
nullable
Exemplegénéré
{
"registration_type": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0",
"note": "example",
"quantity": 1,
"locale": "example"
}

Inscrit

Type de médiaapplication/json
object
id
string format : uuid
status
string
Valeurs autorisées : reserved confirmed cancelled refunded
event
object
id
string
slug
string
title
string
starts_at
string format : date-time
ends_at
string format : date-time
nullable
timezone
string
status
string
location
string
nullable
registration_type
object
uid
string
cod
string
name
string
amount
number
currency
string
quantity
integer
reserved_until
string format : date-time
nullable
checked_in_at
string format : date-time
nullable
cancelled_at
string format : date-time
nullable
cancel_reason
string
nullable
can_cancel
boolean
payment
object
status
string
amount
number
currency
string
method
string
paid_at
string format : date-time
payment_instructions

Comment payer la contribution, tant que l’inscription est réservée

string
nullable
note

Texte libre écrit par la personne. Non transmis (null) aux clients tiers quand l’association a déclaré traiter des catégories particulières de données

string
nullable
created_at
string format : date-time
token

Le contenu du QR de l’inscription (vmt_…), inscriptions confirmées seulement

string
nullable
Exemple
{
"status": "reserved"
}

Requête invalide

Type de médiaapplication/problem+json
object
type
obligatoire
string format : uri
title
obligatoire
string
status
obligatoire
integer
detail
string
code
obligatoire
string
request_id
string
errors
Array<object>
object
field
string
code
string
message
string
Exemplegénéré
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"code": "example",
"request_id": "example",
"errors": [
{
"field": "example",
"code": "example",
"message": "example"
}
]
}

Identifiants manquants ou invalides

Type de médiaapplication/problem+json
object
type
obligatoire
string format : uri
title
obligatoire
string
status
obligatoire
integer
detail
string
code
obligatoire
string
request_id
string
errors
Array<object>
object
field
string
code
string
message
string
Exemplegénéré
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"code": "example",
"request_id": "example",
"errors": [
{
"field": "example",
"code": "example",
"message": "example"
}
]
}

Non autorisé

Type de médiaapplication/problem+json
object
type
obligatoire
string format : uri
title
obligatoire
string
status
obligatoire
integer
detail
string
code
obligatoire
string
request_id
string
errors
Array<object>
object
field
string
code
string
message
string
Exemplegénéré
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"code": "example",
"request_id": "example",
"errors": [
{
"field": "example",
"code": "example",
"message": "example"
}
]
}

Introuvable

Type de médiaapplication/problem+json
object
type
obligatoire
string format : uri
title
obligatoire
string
status
obligatoire
integer
detail
string
code
obligatoire
string
request_id
string
errors
Array<object>
object
field
string
code
string
message
string
Exemplegénéré
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"code": "example",
"request_id": "example",
"errors": [
{
"field": "example",
"code": "example",
"message": "example"
}
]
}

Non éligible (reasons) ou type d’inscription inconnu

Limite de débit atteinte

Type de médiaapplication/problem+json
object
type
obligatoire
string format : uri
title
obligatoire
string
status
obligatoire
integer
detail
string
code
obligatoire
string
request_id
string
errors
Array<object>
object
field
string
code
string
message
string
Exemplegénéré
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"code": "example",
"request_id": "example",
"errors": [
{
"field": "example",
"code": "example",
"message": "example"
}
]
}

Erreur interne

Type de médiaapplication/problem+json
object
type
obligatoire
string format : uri
title
obligatoire
string
status
obligatoire
integer
detail
string
code
obligatoire
string
request_id
string
errors
Array<object>
object
field
string
code
string
message
string
Exemplegénéré
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"code": "example",
"request_id": "example",
"errors": [
{
"field": "example",
"code": "example",
"message": "example"
}
]
}