Deactivate Company
Mark the Company as deactivated and notify internal channels. The record is retained but excluded from active listings.
curl -X PATCH "https://api.getkini.com/companies/123/deactivate/" \
-H "Content-Type: application/json" \
-H "Company-Id: 123" \
-H "Authorization: Bearer YOUR_API_TOKEN"
import requests
import json
url = "https://api.getkini.com/companies/123/deactivate/"
headers = {
"Content-Type": "application/json",
"Company-Id": "123",
"Authorization": "Bearer YOUR_API_TOKEN"
}
response = requests.patch(url, headers=headers)
print(response.json())
const response = await fetch("https://api.getkini.com/companies/123/deactivate/", {
method: "PATCH",
headers: {
"Content-Type": "application/json",
"Company-Id": "123",
"Authorization": "Bearer YOUR_API_TOKEN"
}
});
const data = await response.json();
console.log(data);
package main
import (
"fmt"
"net/http"
)
func main() {
req, err := http.NewRequest("PATCH", "https://api.getkini.com/companies/123/deactivate/", nil)
if err != nil {
panic(err)
}
req.Header.Set("Content-Type", "application/json")
req.Header.Set("Company-Id", "123")
req.Header.Set("Authorization", "Bearer YOUR_API_TOKEN")
client := &http.Client{}
resp, err := client.Do(req)
if err != nil {
panic(err)
}
defer resp.Body.Close()
fmt.Println("Response Status:", resp.Status)
}
require 'net/http'
require 'json'
uri = URI('https://api.getkini.com/companies/123/deactivate/')
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(uri)
request['Content-Type'] = 'application/json'
request['Company-Id'] = '123'
request['Authorization'] = 'Bearer YOUR_API_TOKEN'
response = http.request(request)
puts response.body
{
"detail": "success"
}
{
"error": "Not Found",
"message": "The requested resource was not found",
"code": 404
}
PATCH
/companies/{id}/deactivate/PATCH
Base URLstring
Target server for requests. Edit to use your own host.
Bearer Token
Bearer Tokenstring
RequiredBearer API Key Authentication. Include your API key in the Authorization header.
Bearer API Key Authentication. Include your API key in the Authorization header.
path
idinteger
RequiredUnique Kini ID of the company
header
Company-Idinteger
RequiredKini ID of the company the key is associated with
Request Preview
Response
Response will appear here after sending the request
Authentication
header
Authorizationstring
RequiredBearer token. Bearer API Key Authentication. Include your API key in the Authorization header.
Path Parameters
idinteger
RequiredUnique Kini ID of the company
Headers
Company-Idinteger
RequiredKini ID of the company the key is associated with
Responses
detailstring
Result of the deactivation request
Was this page helpful?