Pular para o conteúdo

Verificar um token: esta carteirinha (ou inscrição em evento) está ativa agora?

GET
/v1/verify/{card_token}
curl --request GET \
--url https://api.vimine.network/v1/verify/example

Preserva a privacidade: devolve só o status e, quando ativa, o fim da validade. Nunca o associado, a associação ou a versão do statuto. O token é verificado primeiro criptograficamente (assinatura, janela de validade), depois com o estado atual da carteirinha. Um token de inscrição em evento (kind: registration) responde com o status da inscrição e o slug + início do evento — nada sobre a pessoa.

card_token
obrigatório

O token vmt_… lido no QR da carteirinha

string

Verificação

Tipo de mídiaapplication/json
object
status
obrigatório
string
Valores permitidos: active inactive
valid_until
string formato: date-time
valid_from

Com reason: not_yet_valid: a carteirinha é autêntica e ativa, e se torna utilizável neste instante

string formato: date-time
reason
string
Valores permitidos: expired invalid not_yet_valid
kind

Presente para os tokens de inscrição

string
Valores permitidos: card registration
event
object
slug
string
starts_at
string formato: date-time
Exemplo
{
"status": "active",
"reason": "expired",
"kind": "card"
}

Requisição inválida

Tipo de mídiaapplication/problem+json
object
type
obrigatório
string formato: uri
title
obrigatório
string
status
obrigatório
integer
detail
string
code
obrigatório
string
request_id
string
errors
Array<object>
object
field
string
code
string
message
string
Exemplogerado
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"code": "example",
"request_id": "example",
"errors": [
{
"field": "example",
"code": "example",
"message": "example"
}
]
}

Não encontrado

Tipo de mídiaapplication/problem+json
object
type
obrigatório
string formato: uri
title
obrigatório
string
status
obrigatório
integer
detail
string
code
obrigatório
string
request_id
string
errors
Array<object>
object
field
string
code
string
message
string
Exemplogerado
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"code": "example",
"request_id": "example",
"errors": [
{
"field": "example",
"code": "example",
"message": "example"
}
]
}

Limite de requisições excedido

Tipo de mídiaapplication/problem+json
object
type
obrigatório
string formato: uri
title
obrigatório
string
status
obrigatório
integer
detail
string
code
obrigatório
string
request_id
string
errors
Array<object>
object
field
string
code
string
message
string
Exemplogerado
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"code": "example",
"request_id": "example",
"errors": [
{
"field": "example",
"code": "example",
"message": "example"
}
]
}

Erro interno

Tipo de mídiaapplication/problem+json
object
type
obrigatório
string formato: uri
title
obrigatório
string
status
obrigatório
integer
detail
string
code
obrigatório
string
request_id
string
errors
Array<object>
object
field
string
code
string
message
string
Exemplogerado
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"code": "example",
"request_id": "example",
"errors": [
{
"field": "example",
"code": "example",
"message": "example"
}
]
}