curl --request POST \
--url https://api.paywithlocus.com/api/credits/agent/signup \
--header 'Content-Type: application/json' \
--data '
{
"email": "[email protected]",
"name": "<string>",
"registrationToken": "<string>"
}
'import requests
url = "https://api.paywithlocus.com/api/credits/agent/signup"
payload = {
"email": "[email protected]",
"name": "<string>",
"registrationToken": "<string>"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({email: '[email protected]', name: '<string>', registrationToken: '<string>'})
};
fetch('https://api.paywithlocus.com/api/credits/agent/signup', 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.paywithlocus.com/api/credits/agent/signup",
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([
'email' => '[email protected]',
'name' => '<string>',
'registrationToken' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"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.paywithlocus.com/api/credits/agent/signup"
payload := strings.NewReader("{\n \"email\": \"[email protected]\",\n \"name\": \"<string>\",\n \"registrationToken\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
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.paywithlocus.com/api/credits/agent/signup")
.header("Content-Type", "application/json")
.body("{\n \"email\": \"[email protected]\",\n \"name\": \"<string>\",\n \"registrationToken\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.paywithlocus.com/api/credits/agent/signup")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"email\": \"[email protected]\",\n \"name\": \"<string>\",\n \"registrationToken\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"account": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"status": "<string>",
"onboardingState": "funding_required",
"balance": {
"usd": "<string>",
"credits": "<string>",
"creditsPerDollar": "<string>"
},
"connection": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"keyPrefix": "<string>",
"expiresAt": "2023-11-07T05:31:56Z",
"credential": "<string>"
},
"identity": {
"provider": "agentid",
"email": "[email protected]"
},
"mcp": {},
"links": {},
"nextAction": {},
"activated": true,
"created": true,
"credentialRenewed": true,
"credentialRecovered": true
}
}{
"success": true,
"account": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"status": "<string>",
"onboardingState": "funding_required",
"balance": {
"usd": "<string>",
"credits": "<string>",
"creditsPerDollar": "<string>"
},
"connection": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"keyPrefix": "<string>",
"expiresAt": "2023-11-07T05:31:56Z",
"credential": "<string>"
},
"identity": {
"provider": "agentid",
"email": "[email protected]"
},
"mcp": {},
"links": {},
"nextAction": {},
"activated": true,
"created": true,
"credentialRenewed": true,
"credentialRecovered": true
}
}Create an agent account with the human owner's email
Ask the human before using this route. Creates a new zero-balance agent workspace and returns its scoped lcac_ connection credential at once. The named human receives a one-time claim link; opening it makes them an owner of every pending agent account for that address, and “This wasn’t me” suspends them. Replaying the same email, name, and registrationToken returns the same workspace and credential. Every new token creates a new workspace; an existing workspace is never joined by email. No free or bonus credits are issued.
curl --request POST \
--url https://api.paywithlocus.com/api/credits/agent/signup \
--header 'Content-Type: application/json' \
--data '
{
"email": "[email protected]",
"name": "<string>",
"registrationToken": "<string>"
}
'import requests
url = "https://api.paywithlocus.com/api/credits/agent/signup"
payload = {
"email": "[email protected]",
"name": "<string>",
"registrationToken": "<string>"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({email: '[email protected]', name: '<string>', registrationToken: '<string>'})
};
fetch('https://api.paywithlocus.com/api/credits/agent/signup', 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.paywithlocus.com/api/credits/agent/signup",
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([
'email' => '[email protected]',
'name' => '<string>',
'registrationToken' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"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.paywithlocus.com/api/credits/agent/signup"
payload := strings.NewReader("{\n \"email\": \"[email protected]\",\n \"name\": \"<string>\",\n \"registrationToken\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
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.paywithlocus.com/api/credits/agent/signup")
.header("Content-Type", "application/json")
.body("{\n \"email\": \"[email protected]\",\n \"name\": \"<string>\",\n \"registrationToken\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.paywithlocus.com/api/credits/agent/signup")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"email\": \"[email protected]\",\n \"name\": \"<string>\",\n \"registrationToken\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"account": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"status": "<string>",
"onboardingState": "funding_required",
"balance": {
"usd": "<string>",
"credits": "<string>",
"creditsPerDollar": "<string>"
},
"connection": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"keyPrefix": "<string>",
"expiresAt": "2023-11-07T05:31:56Z",
"credential": "<string>"
},
"identity": {
"provider": "agentid",
"email": "[email protected]"
},
"mcp": {},
"links": {},
"nextAction": {},
"activated": true,
"created": true,
"credentialRenewed": true,
"credentialRecovered": true
}
}{
"success": true,
"account": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"status": "<string>",
"onboardingState": "funding_required",
"balance": {
"usd": "<string>",
"credits": "<string>",
"creditsPerDollar": "<string>"
},
"connection": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"keyPrefix": "<string>",
"expiresAt": "2023-11-07T05:31:56Z",
"credential": "<string>"
},
"identity": {
"provider": "agentid",
"email": "[email protected]"
},
"mcp": {},
"links": {},
"nextAction": {},
"activated": true,
"created": true,
"credentialRenewed": true,
"credentialRecovered": true
}
}Body
The human owner's address. It receives a one-time claim link and is not treated as verified until the link is opened.
320Agent and workspace name. Control and bidirectional-formatting characters are rejected.
1 - 100Canonical base64url encoding of 24 bytes generated by a cryptographically secure random-number generator.
^[A-Za-z0-9_-]{32}$