Update account password
curl --request PUT \
--url https://app.oryzacloud.app/api/client/account/password \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"password": "correct horse battery staple",
"current_password": "current-password",
"password_confirmation": "correct-horse-battery-staple"
}
'import requests
url = "https://app.oryzacloud.app/api/client/account/password"
payload = {
"password": "correct horse battery staple",
"current_password": "current-password",
"password_confirmation": "correct-horse-battery-staple"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
password: 'correct horse battery staple',
current_password: 'current-password',
password_confirmation: 'correct-horse-battery-staple'
})
};
fetch('https://app.oryzacloud.app/api/client/account/password', 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://app.oryzacloud.app/api/client/account/password",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'password' => 'correct horse battery staple',
'current_password' => 'current-password',
'password_confirmation' => 'correct-horse-battery-staple'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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://app.oryzacloud.app/api/client/account/password"
payload := strings.NewReader("{\n \"password\": \"correct horse battery staple\",\n \"current_password\": \"current-password\",\n \"password_confirmation\": \"correct-horse-battery-staple\"\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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.put("https://app.oryzacloud.app/api/client/account/password")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"password\": \"correct horse battery staple\",\n \"current_password\": \"current-password\",\n \"password_confirmation\": \"correct-horse-battery-staple\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.oryzacloud.app/api/client/account/password")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"password\": \"correct horse battery staple\",\n \"current_password\": \"current-password\",\n \"password_confirmation\": \"correct-horse-battery-staple\"\n}"
response = http.request(request)
puts response.read_body{
"errors": [
{
"code": "<string>",
"status": "<string>",
"detail": "<string>"
}
]
}{
"errors": [
{
"code": "<string>",
"status": "<string>",
"detail": "<string>"
}
]
}{
"errors": [
{
"code": "<string>",
"status": "<string>",
"detail": "<string>"
}
]
}{
"errors": [
{
"code": "<string>",
"status": "<string>",
"detail": "<string>",
"source": {
"field": "<string>"
}
}
]
}Conta
Atualizar Senha
Altera a senha de acesso da conta.
PUT
/
api
/
client
/
account
/
password
Update account password
curl --request PUT \
--url https://app.oryzacloud.app/api/client/account/password \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"password": "correct horse battery staple",
"current_password": "current-password",
"password_confirmation": "correct-horse-battery-staple"
}
'import requests
url = "https://app.oryzacloud.app/api/client/account/password"
payload = {
"password": "correct horse battery staple",
"current_password": "current-password",
"password_confirmation": "correct-horse-battery-staple"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
password: 'correct horse battery staple',
current_password: 'current-password',
password_confirmation: 'correct-horse-battery-staple'
})
};
fetch('https://app.oryzacloud.app/api/client/account/password', 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://app.oryzacloud.app/api/client/account/password",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'password' => 'correct horse battery staple',
'current_password' => 'current-password',
'password_confirmation' => 'correct-horse-battery-staple'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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://app.oryzacloud.app/api/client/account/password"
payload := strings.NewReader("{\n \"password\": \"correct horse battery staple\",\n \"current_password\": \"current-password\",\n \"password_confirmation\": \"correct-horse-battery-staple\"\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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.put("https://app.oryzacloud.app/api/client/account/password")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"password\": \"correct horse battery staple\",\n \"current_password\": \"current-password\",\n \"password_confirmation\": \"correct-horse-battery-staple\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.oryzacloud.app/api/client/account/password")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"password\": \"correct horse battery staple\",\n \"current_password\": \"current-password\",\n \"password_confirmation\": \"correct-horse-battery-staple\"\n}"
response = http.request(request)
puts response.read_body{
"errors": [
{
"code": "<string>",
"status": "<string>",
"detail": "<string>"
}
]
}{
"errors": [
{
"code": "<string>",
"status": "<string>",
"detail": "<string>"
}
]
}{
"errors": [
{
"code": "<string>",
"status": "<string>",
"detail": "<string>"
}
]
}{
"errors": [
{
"code": "<string>",
"status": "<string>",
"detail": "<string>",
"source": {
"field": "<string>"
}
}
]
}string
obrigatório
Chave Client API da sua conta. Você pode gerá-la em Configurações da Conta.
Resposta
string
Tipo de recurso retornado pela API (ex:
server, stats, list, api_key).object
Atributos detalhados do recurso retornado.
Exemplo de Uso
curl -X PUT "https://app.oryzacloud.app/api/client/account/password" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer SUA_CHAVE_CLIENT_API"
const response = await fetch("https://app.oryzacloud.app/api/client/account/password", {
method: "PUT",
headers: {
"Accept": "application/json",
"Content-Type": "application/json",
"Authorization": "Bearer SUA_CHAVE_CLIENT_API"
}
});
const data = await response.json();
console.log(data);
Autorizações
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Corpo
application/json
The password. Must be at least 8 characters.
Exemplo:
"correct horse battery staple"
The current account password.
Exemplo:
"current-password"
Confirmation matching the new password.
Exemplo:
"correct-horse-battery-staple"
Resposta
Password updated.