User
Get user profile (id)
Gets a specific user profile via user id.
Parameters for "Get user profile (id)"
GET/API/User/{userId}
Request Example
curl -X GET 'https://mgmtapi.geins.io/API/User/{userId}' \
-H 'Accept: application/json' \
-H 'Content-Type: application/json' \
-H 'Authorization: Basic [USER-CREDENTIALS-BASE64-ENCODED]' \
-H 'X-ApiKey: {MGMT_API_KEY}'
import axios from 'axios';
const config = {
method: 'GET',
url: 'https://mgmtapi.geins.io/API/User/{userId}',
headers: {
'Accept': 'application/json',
'Content-Type': 'application/json',
'Authorization': 'Basic [USER-CREDENTIALS-BASE64-ENCODED]',
'X-ApiKey': '{MGMT_API_KEY}'
},
};
axios.request(config)
.then(response => response.data)
.catch(error => console.error(error));
fetch('https://mgmtapi.geins.io/API/User/{userId}', {
method: 'GET',
headers: {
'Accept': 'application/json',
'Content-Type': 'application/json',
'Authorization': 'Basic [USER-CREDENTIALS-BASE64-ENCODED]',
'X-ApiKey': '{MGMT_API_KEY}'
}
})
.then(res => res.json())
.then((response) => response)
.catch(console.error);
import requests
url = "https://mgmtapi.geins.io/API/User/{userId}"
headers = {
'Accept': 'application/json',
'Content-Type': 'application/json',
'Authorization': 'Basic [USER-CREDENTIALS-BASE64-ENCODED]',
'X-ApiKey': '{MGMT_API_KEY}'
}
response = requests.GET(url, headers=headers)
print(response.json())
package main
import (
"bytes"
"fmt"
"io"
"net/http"
)
func main() {
url := "https://mgmtapi.geins.io/API/User/{userId}"
payload := []byte{}
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Accept", "application/json")
req.Header.Add("Content-Type", "application/json")
req.Header.Add("Authorization", "Basic [USER-CREDENTIALS-BASE64-ENCODED]")
req.Header.Add("X-ApiKey", "{MGMT_API_KEY}")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}
using System.Text;
using System.Text.Json;
using System.Net.Http;
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("Authorization", "Basic [USER-CREDENTIALS-BASE64-ENCODED]");
client.DefaultRequestHeaders.Add("X-ApiKey", "{MGMT_API_KEY}");
var response = await client.GETAsync("https://mgmtapi.geins.io/API/User/{userId}", null);
var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
Response
{
"Resource": {
"UserId": 0,
"SiteId": 0,
"Email": "string",
"FirstName": "string",
"LastName": "string",
"PhoneNr": "string",
"MobilePhoneNr": "string",
"Company": "string",
"Address": "string",
"Address2": "string",
"Address3": "string",
"DoorCode": "string",
"PersonalId": "string",
"Birthyear": "string",
"Zip": "string",
"City": "string",
"CareOf": "string",
"Country": "string",
"State": "string",
"CustomerGroupId": 0,
"CustomerGroupName": "string",
"MemberId": 0,
"MemberType": "string",
"CountryId": 0,
"UserTypeId": 0,
"GenderType": 0,
"MemberDiscount": 0,
"Newsletter": true,
"Blacklisted": true,
"Active": true,
"CreatedOn": "string",
"UpdatedOn": "string",
"MetaData": "string",
"BlacklistedOn": "string",
"BlacklistReason": "string"
},
"Message": "string",
"Details": [
"string"
]
}
{
"Message": "string",
"Details": [
"string"
]
}
{
"Message": "string",
"Details": [
"string"
]
}
Query user profiles
Queries user profiles and stores the result in a batch. Results are fetched from this batch one page at a time via subsequent requests. BatchId is mandatory when fetching any page other than the first page. If no BatchId is provided for the first page, a new batch is created and the id for that batch can be found in the response.
Create user profile