cURL
curl -X POST "https://api.joinformal.com/core.v1.NativeUserService/UpdateNativeUserV3" \
-H "X-API-KEY: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"example": "value"
}'fetch("https://api.joinformal.com/core.v1.NativeUserService/UpdateNativeUserV3", {
method: "POST",
headers: {
"X-API-KEY": "YOUR_API_KEY",
"Content-Type": "application/json"
},
body: JSON.stringify({
example: "value"
})
})
.then(response => response.json())
.then(data => console.log(data))
.catch(error => console.error(error));import requests
url = "https://api.joinformal.com/core.v1.NativeUserService/UpdateNativeUserV3"
headers = {
"X-API-KEY": "YOUR_API_KEY",
"Content-Type": "application/json"
}
data = {
"example": "value"
}
response = requests.post(url, headers=headers, json=data)
print(response.json())package main
import (
"bytes"
"encoding/json"
"fmt"
"io"
"net/http"
)
func main() {
url := "https://api.joinformal.com/core.v1.NativeUserService/UpdateNativeUserV3"
body := map[string]string{
"example": "value",
}
jsonData, _ := json.Marshal(body)
req, _ := http.NewRequest("POST", url, bytes.NewBuffer(jsonData))
req.Header.Set("X-API-KEY", "YOUR_API_KEY")
req.Header.Set("Content-Type", "application/json")
client := &http.Client{}
resp, err := client.Do(req)
if err != nil {
panic(err)
}
defer resp.Body.Close()
responseBody, _ := io.ReadAll(resp.Body)
fmt.Println(string(responseBody))
}<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.joinformal.com/core.v1.NativeUserService/UpdateNativeUserV3",
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([
'id' => '<string>',
'label' => '<string>',
'terminationProtection' => true,
'credentials' => [
'awsIam' => [
'username' => '<string>',
'role' => '<string>'
],
'azureIam' => [
'username' => '<string>'
],
'gcpIam' => [
'username' => '<string>'
],
'hook' => [
'hook' => '<string>',
'allowlistedEnvVariables' => [
'<string>'
],
'allowlistedNetworkHosts' => [
'<string>'
]
]
]
]),
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;
}HttpResponse<String> response = Unirest.post("https://api.joinformal.com/core.v1.NativeUserService/UpdateNativeUserV3")
.header("X-API-KEY", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"id\": \"<string>\",\n \"label\": \"<string>\",\n \"terminationProtection\": true,\n \"credentials\": {\n \"awsIam\": {\n \"username\": \"<string>\",\n \"role\": \"<string>\"\n },\n \"azureIam\": {\n \"username\": \"<string>\"\n },\n \"gcpIam\": {\n \"username\": \"<string>\"\n },\n \"hook\": {\n \"hook\": \"<string>\",\n \"allowlistedEnvVariables\": [\n \"<string>\"\n ],\n \"allowlistedNetworkHosts\": [\n \"<string>\"\n ]\n }\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.joinformal.com/core.v1.NativeUserService/UpdateNativeUserV3")
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 \"id\": \"<string>\",\n \"label\": \"<string>\",\n \"terminationProtection\": true,\n \"credentials\": {\n \"awsIam\": {\n \"username\": \"<string>\",\n \"role\": \"<string>\"\n },\n \"azureIam\": {\n \"username\": \"<string>\"\n },\n \"gcpIam\": {\n \"username\": \"<string>\"\n },\n \"hook\": {\n \"hook\": \"<string>\",\n \"allowlistedEnvVariables\": [\n \"<string>\"\n ],\n \"allowlistedNetworkHosts\": [\n \"<string>\"\n ]\n }\n }\n}"
response = http.request(request)
puts response.read_body{
"nativeUser": {
"credentials": {
"awsIam": {
"username": "<string>",
"role": "<string>"
},
"azureIam": {
"username": "<string>"
},
"basic": {
"password": {
"environmentVariable": "<string>",
"literal": "<string>"
},
"username": "<string>"
},
"gcpIam": {
"username": "<string>"
},
"hook": {
"hook": "<string>",
"allowlistedEnvVariables": [
"<string>"
],
"allowlistedNetworkHosts": [
"<string>"
]
},
"httpApiKeyHeader": {
"value": {
"environmentVariable": "<string>",
"literal": "<string>"
},
"key": "<string>"
},
"httpApiKeyQuery": {
"value": {
"environmentVariable": "<string>",
"literal": "<string>"
},
"key": "<string>"
},
"httpBasic": {
"password": {
"environmentVariable": "<string>",
"literal": "<string>"
},
"header": "<string>",
"username": "<string>"
},
"httpBearer": {
"token": {
"environmentVariable": "<string>",
"literal": "<string>"
},
"header": "<string>"
},
"kubernetesInline": {
"kubeconfig": {
"environmentVariable": "<string>",
"literal": "<string>"
}
},
"kubernetesPath": {
"kubeconfigPath": {
"environmentVariable": "<string>",
"literal": "<string>"
}
},
"snowflakeKey": {
"key": {
"environmentVariable": "<string>",
"literal": "<string>"
},
"username": "<string>"
},
"sshKey": {
"key": {
"environmentVariable": "<string>",
"literal": "<string>"
},
"username": "<string>",
"certificate": {
"environmentVariable": "<string>",
"literal": "<string>"
}
}
},
"id": "<string>",
"resourceId": "<string>",
"label": "<string>",
"terminationProtection": true,
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z"
}
}{
"code": "invalid_request",
"message": "Invalid request parameters",
"details": {}
}{
"code": "unauthorized",
"message": "Authentication required"
}{
"code": "forbidden",
"message": "Insufficient permissions to perform this action"
}{
"code": "not_found",
"message": "Resource not found"
}{
"code": "internal_error",
"message": "An internal error occurred"
}core.v1.NativeUserService
Update native user
Updates a native user. Leave credentials unset to keep existing credentials. The credential type cannot be changed.
POST
/
core.v1.NativeUserService
/
UpdateNativeUserV3
cURL
curl -X POST "https://api.joinformal.com/core.v1.NativeUserService/UpdateNativeUserV3" \
-H "X-API-KEY: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"example": "value"
}'fetch("https://api.joinformal.com/core.v1.NativeUserService/UpdateNativeUserV3", {
method: "POST",
headers: {
"X-API-KEY": "YOUR_API_KEY",
"Content-Type": "application/json"
},
body: JSON.stringify({
example: "value"
})
})
.then(response => response.json())
.then(data => console.log(data))
.catch(error => console.error(error));import requests
url = "https://api.joinformal.com/core.v1.NativeUserService/UpdateNativeUserV3"
headers = {
"X-API-KEY": "YOUR_API_KEY",
"Content-Type": "application/json"
}
data = {
"example": "value"
}
response = requests.post(url, headers=headers, json=data)
print(response.json())package main
import (
"bytes"
"encoding/json"
"fmt"
"io"
"net/http"
)
func main() {
url := "https://api.joinformal.com/core.v1.NativeUserService/UpdateNativeUserV3"
body := map[string]string{
"example": "value",
}
jsonData, _ := json.Marshal(body)
req, _ := http.NewRequest("POST", url, bytes.NewBuffer(jsonData))
req.Header.Set("X-API-KEY", "YOUR_API_KEY")
req.Header.Set("Content-Type", "application/json")
client := &http.Client{}
resp, err := client.Do(req)
if err != nil {
panic(err)
}
defer resp.Body.Close()
responseBody, _ := io.ReadAll(resp.Body)
fmt.Println(string(responseBody))
}<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.joinformal.com/core.v1.NativeUserService/UpdateNativeUserV3",
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([
'id' => '<string>',
'label' => '<string>',
'terminationProtection' => true,
'credentials' => [
'awsIam' => [
'username' => '<string>',
'role' => '<string>'
],
'azureIam' => [
'username' => '<string>'
],
'gcpIam' => [
'username' => '<string>'
],
'hook' => [
'hook' => '<string>',
'allowlistedEnvVariables' => [
'<string>'
],
'allowlistedNetworkHosts' => [
'<string>'
]
]
]
]),
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;
}HttpResponse<String> response = Unirest.post("https://api.joinformal.com/core.v1.NativeUserService/UpdateNativeUserV3")
.header("X-API-KEY", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"id\": \"<string>\",\n \"label\": \"<string>\",\n \"terminationProtection\": true,\n \"credentials\": {\n \"awsIam\": {\n \"username\": \"<string>\",\n \"role\": \"<string>\"\n },\n \"azureIam\": {\n \"username\": \"<string>\"\n },\n \"gcpIam\": {\n \"username\": \"<string>\"\n },\n \"hook\": {\n \"hook\": \"<string>\",\n \"allowlistedEnvVariables\": [\n \"<string>\"\n ],\n \"allowlistedNetworkHosts\": [\n \"<string>\"\n ]\n }\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.joinformal.com/core.v1.NativeUserService/UpdateNativeUserV3")
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 \"id\": \"<string>\",\n \"label\": \"<string>\",\n \"terminationProtection\": true,\n \"credentials\": {\n \"awsIam\": {\n \"username\": \"<string>\",\n \"role\": \"<string>\"\n },\n \"azureIam\": {\n \"username\": \"<string>\"\n },\n \"gcpIam\": {\n \"username\": \"<string>\"\n },\n \"hook\": {\n \"hook\": \"<string>\",\n \"allowlistedEnvVariables\": [\n \"<string>\"\n ],\n \"allowlistedNetworkHosts\": [\n \"<string>\"\n ]\n }\n }\n}"
response = http.request(request)
puts response.read_body{
"nativeUser": {
"credentials": {
"awsIam": {
"username": "<string>",
"role": "<string>"
},
"azureIam": {
"username": "<string>"
},
"basic": {
"password": {
"environmentVariable": "<string>",
"literal": "<string>"
},
"username": "<string>"
},
"gcpIam": {
"username": "<string>"
},
"hook": {
"hook": "<string>",
"allowlistedEnvVariables": [
"<string>"
],
"allowlistedNetworkHosts": [
"<string>"
]
},
"httpApiKeyHeader": {
"value": {
"environmentVariable": "<string>",
"literal": "<string>"
},
"key": "<string>"
},
"httpApiKeyQuery": {
"value": {
"environmentVariable": "<string>",
"literal": "<string>"
},
"key": "<string>"
},
"httpBasic": {
"password": {
"environmentVariable": "<string>",
"literal": "<string>"
},
"header": "<string>",
"username": "<string>"
},
"httpBearer": {
"token": {
"environmentVariable": "<string>",
"literal": "<string>"
},
"header": "<string>"
},
"kubernetesInline": {
"kubeconfig": {
"environmentVariable": "<string>",
"literal": "<string>"
}
},
"kubernetesPath": {
"kubeconfigPath": {
"environmentVariable": "<string>",
"literal": "<string>"
}
},
"snowflakeKey": {
"key": {
"environmentVariable": "<string>",
"literal": "<string>"
},
"username": "<string>"
},
"sshKey": {
"key": {
"environmentVariable": "<string>",
"literal": "<string>"
},
"username": "<string>",
"certificate": {
"environmentVariable": "<string>",
"literal": "<string>"
}
}
},
"id": "<string>",
"resourceId": "<string>",
"label": "<string>",
"terminationProtection": true,
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z"
}
}{
"code": "invalid_request",
"message": "Invalid request parameters",
"details": {}
}{
"code": "unauthorized",
"message": "Authentication required"
}{
"code": "forbidden",
"message": "Insufficient permissions to perform this action"
}{
"code": "not_found",
"message": "Resource not found"
}{
"code": "internal_error",
"message": "An internal error occurred"
}Authorizations
API key authentication. Get your API key from the Formal console.
Body
application/json
Minimum string length:
1Unique label per resource. See NativeUserV3.label.
Minimum string length:
1Leave credentials unset to keep the existing credential source. If set, all fields of the selected static type or hook source must be provided. The credential variant cannot be changed, including between static and hook-backed credentials. Create a new native user to use another variant.
Show child attributes
Show child attributes
Response
Success
Show child attributes
Show child attributes
Was this page helpful?
⌘I