Register a new company.
curl --request POST \
--url https://core.grdd.dev/api/company/register \
--header 'Content-Type: application/json' \
--data '
{
"name": "name",
"griddid": "griddid",
"mainEmail": "mainEmail",
"password": "password",
"confirmPassword": "confirmPassword",
"mainPhone": "mainPhone",
"notes": "notes",
"address": "address",
"mode": "dry",
"coType": "IO"
}
'import requests
url = "https://core.grdd.dev/api/company/register"
payload = {
"name": "name",
"griddid": "griddid",
"mainEmail": "mainEmail",
"password": "password",
"confirmPassword": "confirmPassword",
"mainPhone": "mainPhone",
"notes": "notes",
"address": "address",
"mode": "dry",
"coType": "IO"
}
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({
name: 'name',
griddid: 'griddid',
mainEmail: 'mainEmail',
password: 'password',
confirmPassword: 'confirmPassword',
mainPhone: 'mainPhone',
notes: 'notes',
address: 'address',
mode: 'dry',
coType: 'IO'
})
};
fetch('https://core.grdd.dev/api/company/register', 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://core.grdd.dev/api/company/register",
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([
'name' => 'name',
'griddid' => 'griddid',
'mainEmail' => 'mainEmail',
'password' => 'password',
'confirmPassword' => 'confirmPassword',
'mainPhone' => 'mainPhone',
'notes' => 'notes',
'address' => 'address',
'mode' => 'dry',
'coType' => 'IO'
]),
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://core.grdd.dev/api/company/register"
payload := strings.NewReader("{\n \"name\": \"name\",\n \"griddid\": \"griddid\",\n \"mainEmail\": \"mainEmail\",\n \"password\": \"password\",\n \"confirmPassword\": \"confirmPassword\",\n \"mainPhone\": \"mainPhone\",\n \"notes\": \"notes\",\n \"address\": \"address\",\n \"mode\": \"dry\",\n \"coType\": \"IO\"\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://core.grdd.dev/api/company/register")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"name\",\n \"griddid\": \"griddid\",\n \"mainEmail\": \"mainEmail\",\n \"password\": \"password\",\n \"confirmPassword\": \"confirmPassword\",\n \"mainPhone\": \"mainPhone\",\n \"notes\": \"notes\",\n \"address\": \"address\",\n \"mode\": \"dry\",\n \"coType\": \"IO\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://core.grdd.dev/api/company/register")
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 \"name\": \"name\",\n \"griddid\": \"griddid\",\n \"mainEmail\": \"mainEmail\",\n \"password\": \"password\",\n \"confirmPassword\": \"confirmPassword\",\n \"mainPhone\": \"mainPhone\",\n \"notes\": \"notes\",\n \"address\": \"address\",\n \"mode\": \"dry\",\n \"coType\": \"IO\"\n}"
response = http.request(request)
puts response.read_bodycompany
Register a new company.
If griddid is provided and not registered, it will be used as the company’s griddid. if mode is dry, it will run the validation but not save the data.
POST
/
api
/
company
/
register
Register a new company.
curl --request POST \
--url https://core.grdd.dev/api/company/register \
--header 'Content-Type: application/json' \
--data '
{
"name": "name",
"griddid": "griddid",
"mainEmail": "mainEmail",
"password": "password",
"confirmPassword": "confirmPassword",
"mainPhone": "mainPhone",
"notes": "notes",
"address": "address",
"mode": "dry",
"coType": "IO"
}
'import requests
url = "https://core.grdd.dev/api/company/register"
payload = {
"name": "name",
"griddid": "griddid",
"mainEmail": "mainEmail",
"password": "password",
"confirmPassword": "confirmPassword",
"mainPhone": "mainPhone",
"notes": "notes",
"address": "address",
"mode": "dry",
"coType": "IO"
}
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({
name: 'name',
griddid: 'griddid',
mainEmail: 'mainEmail',
password: 'password',
confirmPassword: 'confirmPassword',
mainPhone: 'mainPhone',
notes: 'notes',
address: 'address',
mode: 'dry',
coType: 'IO'
})
};
fetch('https://core.grdd.dev/api/company/register', 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://core.grdd.dev/api/company/register",
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([
'name' => 'name',
'griddid' => 'griddid',
'mainEmail' => 'mainEmail',
'password' => 'password',
'confirmPassword' => 'confirmPassword',
'mainPhone' => 'mainPhone',
'notes' => 'notes',
'address' => 'address',
'mode' => 'dry',
'coType' => 'IO'
]),
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://core.grdd.dev/api/company/register"
payload := strings.NewReader("{\n \"name\": \"name\",\n \"griddid\": \"griddid\",\n \"mainEmail\": \"mainEmail\",\n \"password\": \"password\",\n \"confirmPassword\": \"confirmPassword\",\n \"mainPhone\": \"mainPhone\",\n \"notes\": \"notes\",\n \"address\": \"address\",\n \"mode\": \"dry\",\n \"coType\": \"IO\"\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://core.grdd.dev/api/company/register")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"name\",\n \"griddid\": \"griddid\",\n \"mainEmail\": \"mainEmail\",\n \"password\": \"password\",\n \"confirmPassword\": \"confirmPassword\",\n \"mainPhone\": \"mainPhone\",\n \"notes\": \"notes\",\n \"address\": \"address\",\n \"mode\": \"dry\",\n \"coType\": \"IO\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://core.grdd.dev/api/company/register")
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 \"name\": \"name\",\n \"griddid\": \"griddid\",\n \"mainEmail\": \"mainEmail\",\n \"password\": \"password\",\n \"confirmPassword\": \"confirmPassword\",\n \"mainPhone\": \"mainPhone\",\n \"notes\": \"notes\",\n \"address\": \"address\",\n \"mode\": \"dry\",\n \"coType\": \"IO\"\n}"
response = http.request(request)
puts response.read_bodyResponse
200
Success
⌘I