Create user metadata
curl --request POST \
--url https://admin.snagsolutions.io/api/users/metadatas \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--data '
{
"userId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"walletAddress": "<string>",
"isBlocked": true,
"epicAccountIdentifier": "<string>",
"discordUser": "<string>",
"discordUserId": "<string>",
"twitterUser": "<string>",
"twitterUserFollowersCount": 123,
"twitterUserId": "<string>",
"emailAddress": "[email protected]",
"walletGroupIdentifier": "<string>",
"userGroupId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"telegramUserId": "<string>",
"telegramUsername": "<string>",
"steamUserId": "<string>",
"steamUsername": "<string>",
"googleUserId": "<string>",
"googleUser": "<string>",
"YTChannelId": "<string>",
"displayName": "<string>",
"location": "<string>",
"bio": "<string>",
"portfolioUrl": "<string>",
"externalLoyaltyScore": "<string>",
"isBlockExempt": true,
"internalNotes": "<string>",
"logoUrl": "<string>",
"userGroupExternalIdentifier": "<string>",
"externalIdentifier": "<string>",
"websiteId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"organizationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"tiktokUser": "<string>",
"tiktokUserId": "<string>",
"sybilScore": 50.5,
"githubUser": "<string>",
"githubUserId": "<string>",
"phoneNumber": "+14155552671"
}
'import requests
url = "https://admin.snagsolutions.io/api/users/metadatas"
payload = {
"userId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"walletAddress": "<string>",
"isBlocked": True,
"epicAccountIdentifier": "<string>",
"discordUser": "<string>",
"discordUserId": "<string>",
"twitterUser": "<string>",
"twitterUserFollowersCount": 123,
"twitterUserId": "<string>",
"emailAddress": "[email protected]",
"walletGroupIdentifier": "<string>",
"userGroupId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"telegramUserId": "<string>",
"telegramUsername": "<string>",
"steamUserId": "<string>",
"steamUsername": "<string>",
"googleUserId": "<string>",
"googleUser": "<string>",
"YTChannelId": "<string>",
"displayName": "<string>",
"location": "<string>",
"bio": "<string>",
"portfolioUrl": "<string>",
"externalLoyaltyScore": "<string>",
"isBlockExempt": True,
"internalNotes": "<string>",
"logoUrl": "<string>",
"userGroupExternalIdentifier": "<string>",
"externalIdentifier": "<string>",
"websiteId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"organizationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"tiktokUser": "<string>",
"tiktokUserId": "<string>",
"sybilScore": 50.5,
"githubUser": "<string>",
"githubUserId": "<string>",
"phoneNumber": "+14155552671"
}
headers = {
"X-API-KEY": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-API-KEY': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
userId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
walletAddress: '<string>',
isBlocked: true,
epicAccountIdentifier: '<string>',
discordUser: '<string>',
discordUserId: '<string>',
twitterUser: '<string>',
twitterUserFollowersCount: 123,
twitterUserId: '<string>',
emailAddress: '[email protected]',
walletGroupIdentifier: '<string>',
userGroupId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
telegramUserId: '<string>',
telegramUsername: '<string>',
steamUserId: '<string>',
steamUsername: '<string>',
googleUserId: '<string>',
googleUser: '<string>',
YTChannelId: '<string>',
displayName: '<string>',
location: '<string>',
bio: '<string>',
portfolioUrl: '<string>',
externalLoyaltyScore: '<string>',
isBlockExempt: true,
internalNotes: '<string>',
logoUrl: '<string>',
userGroupExternalIdentifier: '<string>',
externalIdentifier: '<string>',
websiteId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
organizationId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
tiktokUser: '<string>',
tiktokUserId: '<string>',
sybilScore: 50.5,
githubUser: '<string>',
githubUserId: '<string>',
phoneNumber: '+14155552671'
})
};
fetch('https://admin.snagsolutions.io/api/users/metadatas', 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://admin.snagsolutions.io/api/users/metadatas",
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([
'userId' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'walletAddress' => '<string>',
'isBlocked' => true,
'epicAccountIdentifier' => '<string>',
'discordUser' => '<string>',
'discordUserId' => '<string>',
'twitterUser' => '<string>',
'twitterUserFollowersCount' => 123,
'twitterUserId' => '<string>',
'emailAddress' => '[email protected]',
'walletGroupIdentifier' => '<string>',
'userGroupId' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'telegramUserId' => '<string>',
'telegramUsername' => '<string>',
'steamUserId' => '<string>',
'steamUsername' => '<string>',
'googleUserId' => '<string>',
'googleUser' => '<string>',
'YTChannelId' => '<string>',
'displayName' => '<string>',
'location' => '<string>',
'bio' => '<string>',
'portfolioUrl' => '<string>',
'externalLoyaltyScore' => '<string>',
'isBlockExempt' => true,
'internalNotes' => '<string>',
'logoUrl' => '<string>',
'userGroupExternalIdentifier' => '<string>',
'externalIdentifier' => '<string>',
'websiteId' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'organizationId' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'tiktokUser' => '<string>',
'tiktokUserId' => '<string>',
'sybilScore' => 50.5,
'githubUser' => '<string>',
'githubUserId' => '<string>',
'phoneNumber' => '+14155552671'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-KEY: <api-key>"
],
]);
$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://admin.snagsolutions.io/api/users/metadatas"
payload := strings.NewReader("{\n \"userId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"walletAddress\": \"<string>\",\n \"isBlocked\": true,\n \"epicAccountIdentifier\": \"<string>\",\n \"discordUser\": \"<string>\",\n \"discordUserId\": \"<string>\",\n \"twitterUser\": \"<string>\",\n \"twitterUserFollowersCount\": 123,\n \"twitterUserId\": \"<string>\",\n \"emailAddress\": \"[email protected]\",\n \"walletGroupIdentifier\": \"<string>\",\n \"userGroupId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"telegramUserId\": \"<string>\",\n \"telegramUsername\": \"<string>\",\n \"steamUserId\": \"<string>\",\n \"steamUsername\": \"<string>\",\n \"googleUserId\": \"<string>\",\n \"googleUser\": \"<string>\",\n \"YTChannelId\": \"<string>\",\n \"displayName\": \"<string>\",\n \"location\": \"<string>\",\n \"bio\": \"<string>\",\n \"portfolioUrl\": \"<string>\",\n \"externalLoyaltyScore\": \"<string>\",\n \"isBlockExempt\": true,\n \"internalNotes\": \"<string>\",\n \"logoUrl\": \"<string>\",\n \"userGroupExternalIdentifier\": \"<string>\",\n \"externalIdentifier\": \"<string>\",\n \"websiteId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"organizationId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"tiktokUser\": \"<string>\",\n \"tiktokUserId\": \"<string>\",\n \"sybilScore\": 50.5,\n \"githubUser\": \"<string>\",\n \"githubUserId\": \"<string>\",\n \"phoneNumber\": \"+14155552671\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-API-KEY", "<api-key>")
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://admin.snagsolutions.io/api/users/metadatas")
.header("X-API-KEY", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"userId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"walletAddress\": \"<string>\",\n \"isBlocked\": true,\n \"epicAccountIdentifier\": \"<string>\",\n \"discordUser\": \"<string>\",\n \"discordUserId\": \"<string>\",\n \"twitterUser\": \"<string>\",\n \"twitterUserFollowersCount\": 123,\n \"twitterUserId\": \"<string>\",\n \"emailAddress\": \"[email protected]\",\n \"walletGroupIdentifier\": \"<string>\",\n \"userGroupId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"telegramUserId\": \"<string>\",\n \"telegramUsername\": \"<string>\",\n \"steamUserId\": \"<string>\",\n \"steamUsername\": \"<string>\",\n \"googleUserId\": \"<string>\",\n \"googleUser\": \"<string>\",\n \"YTChannelId\": \"<string>\",\n \"displayName\": \"<string>\",\n \"location\": \"<string>\",\n \"bio\": \"<string>\",\n \"portfolioUrl\": \"<string>\",\n \"externalLoyaltyScore\": \"<string>\",\n \"isBlockExempt\": true,\n \"internalNotes\": \"<string>\",\n \"logoUrl\": \"<string>\",\n \"userGroupExternalIdentifier\": \"<string>\",\n \"externalIdentifier\": \"<string>\",\n \"websiteId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"organizationId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"tiktokUser\": \"<string>\",\n \"tiktokUserId\": \"<string>\",\n \"sybilScore\": 50.5,\n \"githubUser\": \"<string>\",\n \"githubUserId\": \"<string>\",\n \"phoneNumber\": \"+14155552671\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://admin.snagsolutions.io/api/users/metadatas")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-API-KEY"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"userId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"walletAddress\": \"<string>\",\n \"isBlocked\": true,\n \"epicAccountIdentifier\": \"<string>\",\n \"discordUser\": \"<string>\",\n \"discordUserId\": \"<string>\",\n \"twitterUser\": \"<string>\",\n \"twitterUserFollowersCount\": 123,\n \"twitterUserId\": \"<string>\",\n \"emailAddress\": \"[email protected]\",\n \"walletGroupIdentifier\": \"<string>\",\n \"userGroupId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"telegramUserId\": \"<string>\",\n \"telegramUsername\": \"<string>\",\n \"steamUserId\": \"<string>\",\n \"steamUsername\": \"<string>\",\n \"googleUserId\": \"<string>\",\n \"googleUser\": \"<string>\",\n \"YTChannelId\": \"<string>\",\n \"displayName\": \"<string>\",\n \"location\": \"<string>\",\n \"bio\": \"<string>\",\n \"portfolioUrl\": \"<string>\",\n \"externalLoyaltyScore\": \"<string>\",\n \"isBlockExempt\": true,\n \"internalNotes\": \"<string>\",\n \"logoUrl\": \"<string>\",\n \"userGroupExternalIdentifier\": \"<string>\",\n \"externalIdentifier\": \"<string>\",\n \"websiteId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"organizationId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"tiktokUser\": \"<string>\",\n \"tiktokUserId\": \"<string>\",\n \"sybilScore\": 50.5,\n \"githubUser\": \"<string>\",\n \"githubUserId\": \"<string>\",\n \"phoneNumber\": \"+14155552671\"\n}"
response = http.request(request)
puts response.read_body{
"id": "123e4567-e89b-12d3-a456-426614174000",
"websiteId": "123e4567-e89b-12d3-a456-426614174001",
"organizationId": "123e4567-e89b-12d3-a456-426614174002",
"walletGroupIdentifier": "wallet-group-id",
"userGroupId": "user-group-id",
"userGroup": {
"id": "123e4567-e89b-12d3-a456-426614174002",
"externalIdentifier": "user-group-external-id"
},
"user": {
"id": "123e4567-e89b-12d3-a456-426614174002",
"walletAddress": "0x1234567890abcdef1234567890abcdef12345678"
},
"createdAt": "2023-10-01T12:34:56Z"
}{
"message": "Request body is invalid"
}"Forbidden, Could not validate api key"{
"success": false,
"message": "Internal server error",
"debugInfo": "Stack trace or additional error details"
}Identity
Create user metadata
This endpoint is used to create user metadata
POST
/
api
/
users
/
metadatas
Create user metadata
curl --request POST \
--url https://admin.snagsolutions.io/api/users/metadatas \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--data '
{
"userId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"walletAddress": "<string>",
"isBlocked": true,
"epicAccountIdentifier": "<string>",
"discordUser": "<string>",
"discordUserId": "<string>",
"twitterUser": "<string>",
"twitterUserFollowersCount": 123,
"twitterUserId": "<string>",
"emailAddress": "[email protected]",
"walletGroupIdentifier": "<string>",
"userGroupId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"telegramUserId": "<string>",
"telegramUsername": "<string>",
"steamUserId": "<string>",
"steamUsername": "<string>",
"googleUserId": "<string>",
"googleUser": "<string>",
"YTChannelId": "<string>",
"displayName": "<string>",
"location": "<string>",
"bio": "<string>",
"portfolioUrl": "<string>",
"externalLoyaltyScore": "<string>",
"isBlockExempt": true,
"internalNotes": "<string>",
"logoUrl": "<string>",
"userGroupExternalIdentifier": "<string>",
"externalIdentifier": "<string>",
"websiteId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"organizationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"tiktokUser": "<string>",
"tiktokUserId": "<string>",
"sybilScore": 50.5,
"githubUser": "<string>",
"githubUserId": "<string>",
"phoneNumber": "+14155552671"
}
'import requests
url = "https://admin.snagsolutions.io/api/users/metadatas"
payload = {
"userId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"walletAddress": "<string>",
"isBlocked": True,
"epicAccountIdentifier": "<string>",
"discordUser": "<string>",
"discordUserId": "<string>",
"twitterUser": "<string>",
"twitterUserFollowersCount": 123,
"twitterUserId": "<string>",
"emailAddress": "[email protected]",
"walletGroupIdentifier": "<string>",
"userGroupId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"telegramUserId": "<string>",
"telegramUsername": "<string>",
"steamUserId": "<string>",
"steamUsername": "<string>",
"googleUserId": "<string>",
"googleUser": "<string>",
"YTChannelId": "<string>",
"displayName": "<string>",
"location": "<string>",
"bio": "<string>",
"portfolioUrl": "<string>",
"externalLoyaltyScore": "<string>",
"isBlockExempt": True,
"internalNotes": "<string>",
"logoUrl": "<string>",
"userGroupExternalIdentifier": "<string>",
"externalIdentifier": "<string>",
"websiteId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"organizationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"tiktokUser": "<string>",
"tiktokUserId": "<string>",
"sybilScore": 50.5,
"githubUser": "<string>",
"githubUserId": "<string>",
"phoneNumber": "+14155552671"
}
headers = {
"X-API-KEY": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-API-KEY': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
userId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
walletAddress: '<string>',
isBlocked: true,
epicAccountIdentifier: '<string>',
discordUser: '<string>',
discordUserId: '<string>',
twitterUser: '<string>',
twitterUserFollowersCount: 123,
twitterUserId: '<string>',
emailAddress: '[email protected]',
walletGroupIdentifier: '<string>',
userGroupId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
telegramUserId: '<string>',
telegramUsername: '<string>',
steamUserId: '<string>',
steamUsername: '<string>',
googleUserId: '<string>',
googleUser: '<string>',
YTChannelId: '<string>',
displayName: '<string>',
location: '<string>',
bio: '<string>',
portfolioUrl: '<string>',
externalLoyaltyScore: '<string>',
isBlockExempt: true,
internalNotes: '<string>',
logoUrl: '<string>',
userGroupExternalIdentifier: '<string>',
externalIdentifier: '<string>',
websiteId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
organizationId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
tiktokUser: '<string>',
tiktokUserId: '<string>',
sybilScore: 50.5,
githubUser: '<string>',
githubUserId: '<string>',
phoneNumber: '+14155552671'
})
};
fetch('https://admin.snagsolutions.io/api/users/metadatas', 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://admin.snagsolutions.io/api/users/metadatas",
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([
'userId' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'walletAddress' => '<string>',
'isBlocked' => true,
'epicAccountIdentifier' => '<string>',
'discordUser' => '<string>',
'discordUserId' => '<string>',
'twitterUser' => '<string>',
'twitterUserFollowersCount' => 123,
'twitterUserId' => '<string>',
'emailAddress' => '[email protected]',
'walletGroupIdentifier' => '<string>',
'userGroupId' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'telegramUserId' => '<string>',
'telegramUsername' => '<string>',
'steamUserId' => '<string>',
'steamUsername' => '<string>',
'googleUserId' => '<string>',
'googleUser' => '<string>',
'YTChannelId' => '<string>',
'displayName' => '<string>',
'location' => '<string>',
'bio' => '<string>',
'portfolioUrl' => '<string>',
'externalLoyaltyScore' => '<string>',
'isBlockExempt' => true,
'internalNotes' => '<string>',
'logoUrl' => '<string>',
'userGroupExternalIdentifier' => '<string>',
'externalIdentifier' => '<string>',
'websiteId' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'organizationId' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'tiktokUser' => '<string>',
'tiktokUserId' => '<string>',
'sybilScore' => 50.5,
'githubUser' => '<string>',
'githubUserId' => '<string>',
'phoneNumber' => '+14155552671'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-KEY: <api-key>"
],
]);
$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://admin.snagsolutions.io/api/users/metadatas"
payload := strings.NewReader("{\n \"userId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"walletAddress\": \"<string>\",\n \"isBlocked\": true,\n \"epicAccountIdentifier\": \"<string>\",\n \"discordUser\": \"<string>\",\n \"discordUserId\": \"<string>\",\n \"twitterUser\": \"<string>\",\n \"twitterUserFollowersCount\": 123,\n \"twitterUserId\": \"<string>\",\n \"emailAddress\": \"[email protected]\",\n \"walletGroupIdentifier\": \"<string>\",\n \"userGroupId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"telegramUserId\": \"<string>\",\n \"telegramUsername\": \"<string>\",\n \"steamUserId\": \"<string>\",\n \"steamUsername\": \"<string>\",\n \"googleUserId\": \"<string>\",\n \"googleUser\": \"<string>\",\n \"YTChannelId\": \"<string>\",\n \"displayName\": \"<string>\",\n \"location\": \"<string>\",\n \"bio\": \"<string>\",\n \"portfolioUrl\": \"<string>\",\n \"externalLoyaltyScore\": \"<string>\",\n \"isBlockExempt\": true,\n \"internalNotes\": \"<string>\",\n \"logoUrl\": \"<string>\",\n \"userGroupExternalIdentifier\": \"<string>\",\n \"externalIdentifier\": \"<string>\",\n \"websiteId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"organizationId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"tiktokUser\": \"<string>\",\n \"tiktokUserId\": \"<string>\",\n \"sybilScore\": 50.5,\n \"githubUser\": \"<string>\",\n \"githubUserId\": \"<string>\",\n \"phoneNumber\": \"+14155552671\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-API-KEY", "<api-key>")
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://admin.snagsolutions.io/api/users/metadatas")
.header("X-API-KEY", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"userId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"walletAddress\": \"<string>\",\n \"isBlocked\": true,\n \"epicAccountIdentifier\": \"<string>\",\n \"discordUser\": \"<string>\",\n \"discordUserId\": \"<string>\",\n \"twitterUser\": \"<string>\",\n \"twitterUserFollowersCount\": 123,\n \"twitterUserId\": \"<string>\",\n \"emailAddress\": \"[email protected]\",\n \"walletGroupIdentifier\": \"<string>\",\n \"userGroupId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"telegramUserId\": \"<string>\",\n \"telegramUsername\": \"<string>\",\n \"steamUserId\": \"<string>\",\n \"steamUsername\": \"<string>\",\n \"googleUserId\": \"<string>\",\n \"googleUser\": \"<string>\",\n \"YTChannelId\": \"<string>\",\n \"displayName\": \"<string>\",\n \"location\": \"<string>\",\n \"bio\": \"<string>\",\n \"portfolioUrl\": \"<string>\",\n \"externalLoyaltyScore\": \"<string>\",\n \"isBlockExempt\": true,\n \"internalNotes\": \"<string>\",\n \"logoUrl\": \"<string>\",\n \"userGroupExternalIdentifier\": \"<string>\",\n \"externalIdentifier\": \"<string>\",\n \"websiteId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"organizationId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"tiktokUser\": \"<string>\",\n \"tiktokUserId\": \"<string>\",\n \"sybilScore\": 50.5,\n \"githubUser\": \"<string>\",\n \"githubUserId\": \"<string>\",\n \"phoneNumber\": \"+14155552671\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://admin.snagsolutions.io/api/users/metadatas")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-API-KEY"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"userId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"walletAddress\": \"<string>\",\n \"isBlocked\": true,\n \"epicAccountIdentifier\": \"<string>\",\n \"discordUser\": \"<string>\",\n \"discordUserId\": \"<string>\",\n \"twitterUser\": \"<string>\",\n \"twitterUserFollowersCount\": 123,\n \"twitterUserId\": \"<string>\",\n \"emailAddress\": \"[email protected]\",\n \"walletGroupIdentifier\": \"<string>\",\n \"userGroupId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"telegramUserId\": \"<string>\",\n \"telegramUsername\": \"<string>\",\n \"steamUserId\": \"<string>\",\n \"steamUsername\": \"<string>\",\n \"googleUserId\": \"<string>\",\n \"googleUser\": \"<string>\",\n \"YTChannelId\": \"<string>\",\n \"displayName\": \"<string>\",\n \"location\": \"<string>\",\n \"bio\": \"<string>\",\n \"portfolioUrl\": \"<string>\",\n \"externalLoyaltyScore\": \"<string>\",\n \"isBlockExempt\": true,\n \"internalNotes\": \"<string>\",\n \"logoUrl\": \"<string>\",\n \"userGroupExternalIdentifier\": \"<string>\",\n \"externalIdentifier\": \"<string>\",\n \"websiteId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"organizationId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"tiktokUser\": \"<string>\",\n \"tiktokUserId\": \"<string>\",\n \"sybilScore\": 50.5,\n \"githubUser\": \"<string>\",\n \"githubUserId\": \"<string>\",\n \"phoneNumber\": \"+14155552671\"\n}"
response = http.request(request)
puts response.read_body{
"id": "123e4567-e89b-12d3-a456-426614174000",
"websiteId": "123e4567-e89b-12d3-a456-426614174001",
"organizationId": "123e4567-e89b-12d3-a456-426614174002",
"walletGroupIdentifier": "wallet-group-id",
"userGroupId": "user-group-id",
"userGroup": {
"id": "123e4567-e89b-12d3-a456-426614174002",
"externalIdentifier": "user-group-external-id"
},
"user": {
"id": "123e4567-e89b-12d3-a456-426614174002",
"walletAddress": "0x1234567890abcdef1234567890abcdef12345678"
},
"createdAt": "2023-10-01T12:34:56Z"
}{
"message": "Request body is invalid"
}"Forbidden, Could not validate api key"{
"success": false,
"message": "Internal server error",
"debugInfo": "Stack trace or additional error details"
}Authorizations
Body
application/json
Body
Schema for a create user metadata schema
Maximum string length:
128Maximum string length:
128Maximum string length:
128Maximum string length:
255Maximum string length:
255Maximum string length:
255Available options:
sybil_and_multi_account, account_migration, abuse_manipulation, not_sybil, issue_resolved, twitter_suspended, other Maximum string length:
255Required range:
1 <= x <= 100Phone number in E.164 format (e.g., +14155552671)
Pattern:
^\+[1-9]\d{1,14}$Example:
"+14155552671"
Response
200
Schema for a user metadata
Unique identifier for the user metadata
Example:
"123e4567-e89b-12d3-a456-426614174000"
Unique identifier for the website
Example:
"123e4567-e89b-12d3-a456-426614174001"
Unique identifier for the organization
Example:
"123e4567-e89b-12d3-a456-426614174002"
Identifier for the user wallet group set via api
Example:
"wallet-group-id"
Identifier for the user group set via api
Example:
"user-group-id"
User group associated with the user
Show child attributes
Show child attributes
Example:
{
"id": "123e4567-e89b-12d3-a456-426614174002",
"externalIdentifier": "user-group-external-id"
}
Show child attributes
Show child attributes
Timestamp when the wallet was created
Example:
"2023-10-01T12:34:56Z"
Was this page helpful?
⌘I