Gerar Cliente Teste
curl --request POST \
--url https://api.revenda.nexus/lines/test \
--header 'Authorization: <authorization>' \
--header 'Content-Type: application/json' \
--data '
{
"notes": "<string>"
}
'import requests
url = "https://api.revenda.nexus/lines/test"
payload = { "notes": "<string>" }
headers = {
"Authorization": "<authorization>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: '<authorization>', 'Content-Type': 'application/json'},
body: JSON.stringify({notes: '<string>'})
};
fetch('https://api.revenda.nexus/lines/test', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.revenda.nexus/lines/test",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'notes' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.revenda.nexus/lines/test"
payload := strings.NewReader("{\n \"notes\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<authorization>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.revenda.nexus/lines/test")
.header("Authorization", "<authorization>")
.header("Content-Type", "application/json")
.body("{\n \"notes\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.revenda.nexus/lines/test")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<authorization>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"notes\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"id": 1201,
"username": "cliente_teste01",
"password": "senha1234",
"owner": 45,
"expDate": "2025-01-18T15:00:00.000Z",
"notes": "Conta de avaliação",
"status": 1,
"isTrial": 1,
"country": "Brazil",
"createdAt": "2025-01-16T13:00:00.000Z",
"updatedAt": "2025-01-16T13:00:00.000Z",
"whatsapp": null,
"telegram": null,
"idNexus": null,
"migrationUrl": null,
"trash": 0,
"error_nexus": 0,
"updated": 0
}
Clientes
Gerar Cliente Teste
Este endpoint permite gerar um cliente de teste na plataforma Nexus.
POST
/
lines
/
test
Gerar Cliente Teste
curl --request POST \
--url https://api.revenda.nexus/lines/test \
--header 'Authorization: <authorization>' \
--header 'Content-Type: application/json' \
--data '
{
"notes": "<string>"
}
'import requests
url = "https://api.revenda.nexus/lines/test"
payload = { "notes": "<string>" }
headers = {
"Authorization": "<authorization>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: '<authorization>', 'Content-Type': 'application/json'},
body: JSON.stringify({notes: '<string>'})
};
fetch('https://api.revenda.nexus/lines/test', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.revenda.nexus/lines/test",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'notes' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.revenda.nexus/lines/test"
payload := strings.NewReader("{\n \"notes\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<authorization>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.revenda.nexus/lines/test")
.header("Authorization", "<authorization>")
.header("Content-Type", "application/json")
.body("{\n \"notes\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.revenda.nexus/lines/test")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<authorization>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"notes\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"id": 1201,
"username": "cliente_teste01",
"password": "senha1234",
"owner": 45,
"expDate": "2025-01-18T15:00:00.000Z",
"notes": "Conta de avaliação",
"status": 1,
"isTrial": 1,
"country": "Brazil",
"createdAt": "2025-01-16T13:00:00.000Z",
"updatedAt": "2025-01-16T13:00:00.000Z",
"whatsapp": null,
"telegram": null,
"idNexus": null,
"migrationUrl": null,
"trash": 0,
"error_nexus": 0,
"updated": 0
}
Como utilizar este endpoint?
Esse endpoint cria um cliente teste com credenciais temporárias para uso da plataforma.Headers obrigatórios
string
required
O token de autenticação no formato Bearer é obrigatório para acessar este
endpoint.
Parâmetros do corpo da requisição (Payload)
string
Observações adicionais sobre o cliente teste. Campo opcional.
Exemplo de Requisição
POST https://api.revenda.nexus/lines/test
Headers:
{
"Authorization": "Bearer seu_token_aqui",
"Content-Type": "application/json"
}
Payload:
{
"notes": "Cliente teste para avaliação",
}
Resposta
number
Indica o código HTTP da resposta. Esperado: 201 (Created).
string
O código de status da resposta.
object
Conteúdo da resposta.
Show Mostrar objeto
Show Mostrar objeto
number
Identificador único do cliente teste gerado.
string
Nome de usuário gerado para o cliente.
string
Senha temporária gerada para o cliente.
number
ID do proprietário responsável pelo cliente.
string
Data de expiração do acesso do cliente teste.
string
Observações adicionais sobre o cliente teste.
number
Status da conta (ex.: 1 para ativo, 0 para inativo).
number
Indica se a conta é de teste (1 para sim, 0 para não).
string
País de origem do cliente teste.
string
Data de criação do cliente teste.
string
Data da última atualização do cliente teste.
Exemplo de Resposta
{
"id": 1201,
"username": "cliente_teste01",
"password": "senha1234",
"owner": 45,
"expDate": "2025-01-18T15:00:00.000Z",
"notes": "Conta de avaliação",
"status": 1,
"isTrial": 1,
"country": "Brazil",
"createdAt": "2025-01-16T13:00:00.000Z",
"updatedAt": "2025-01-16T13:00:00.000Z",
"whatsapp": null,
"telegram": null,
"idNexus": null,
"migrationUrl": null,
"trash": 0,
"error_nexus": 0,
"updated": 0
}
⌘I

