Get all companies
curl --request GET \
--url https://api.hubapi.com/companies/v2/companies/pagedimport requests
url = "https://api.hubapi.com/companies/v2/companies/paged"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.hubapi.com/companies/v2/companies/paged', 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://api.hubapi.com/companies/v2/companies/paged",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.hubapi.com/companies/v2/companies/paged"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.hubapi.com/companies/v2/companies/paged")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.hubapi.com/companies/v2/companies/paged")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"companies": [
{
"portalId": 62515,
"additionalDomains": [],
"properties": {
"website": {
"sourceId": null,
"timestamp": 1457513066540,
"versions": [
{
"timestamp": 1457513066540,
"sourceVid": [],
"name": "website",
"value": "example.com",
"source": "COMPANIES"
}
],
"value": "example.com",
"source": "COMPANIES"
},
"name": {
"sourceId": "name",
"timestamp": 1464484587592,
"versions": [
{
"name": "name",
"sourceId": "name",
"timestamp": 1464484587592,
"value": "Example Company",
"source": "BIDEN",
"sourceVid": []
}
],
"value": "Example Company",
"source": "BIDEN"
}
},
"isDeleted": false,
"companyId": 115200636
},
{
"portalId": 62515,
"additionalDomains": [],
"properties": {
"website": {
"sourceId": null,
"timestamp": 1457535205549,
"versions": [
{
"timestamp": 1457535205549,
"sourceVid": [],
"name": "website",
"value": "test.com",
"source": "COMPANIES"
}
],
"value": "test.com",
"source": "COMPANIES"
},
"name": {
"sourceId": "name",
"timestamp": 1468832771769,
"versions": [
{
"name": "name",
"sourceId": "name",
"timestamp": 1468832771769,
"value": "Test Company",
"source": "BIDEN",
"sourceVid": []
}
],
"value": "Test Company",
"source": "BIDEN"
}
},
"isDeleted": false,
"companyId": 115279791
}
],
"has-more": true,
"offset": 115279791
}v2
Get all companies
Retrieve all companies in a HubSpot account. This endpoint can be useful when needing to sync company data from HubSpot. For example, if you install an app that integrates HubSpot with an Enterprise Resource Planning (ERP) app, that app may want to get all the company records stored in the CRM. It could then match them to customer records stored in the ERP and use webhooks to get incremental updates.
GET
/
companies
/
v2
/
companies
/
paged
Get all companies
curl --request GET \
--url https://api.hubapi.com/companies/v2/companies/pagedimport requests
url = "https://api.hubapi.com/companies/v2/companies/paged"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.hubapi.com/companies/v2/companies/paged', 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://api.hubapi.com/companies/v2/companies/paged",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.hubapi.com/companies/v2/companies/paged"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.hubapi.com/companies/v2/companies/paged")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.hubapi.com/companies/v2/companies/paged")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"companies": [
{
"portalId": 62515,
"additionalDomains": [],
"properties": {
"website": {
"sourceId": null,
"timestamp": 1457513066540,
"versions": [
{
"timestamp": 1457513066540,
"sourceVid": [],
"name": "website",
"value": "example.com",
"source": "COMPANIES"
}
],
"value": "example.com",
"source": "COMPANIES"
},
"name": {
"sourceId": "name",
"timestamp": 1464484587592,
"versions": [
{
"name": "name",
"sourceId": "name",
"timestamp": 1464484587592,
"value": "Example Company",
"source": "BIDEN",
"sourceVid": []
}
],
"value": "Example Company",
"source": "BIDEN"
}
},
"isDeleted": false,
"companyId": 115200636
},
{
"portalId": 62515,
"additionalDomains": [],
"properties": {
"website": {
"sourceId": null,
"timestamp": 1457535205549,
"versions": [
{
"timestamp": 1457535205549,
"sourceVid": [],
"name": "website",
"value": "test.com",
"source": "COMPANIES"
}
],
"value": "test.com",
"source": "COMPANIES"
},
"name": {
"sourceId": "name",
"timestamp": 1468832771769,
"versions": [
{
"name": "name",
"sourceId": "name",
"timestamp": 1468832771769,
"value": "Test Company",
"source": "BIDEN",
"sourceVid": []
}
],
"value": "Test Company",
"source": "BIDEN"
}
},
"isDeleted": false,
"companyId": 115279791
}
],
"has-more": true,
"offset": 115279791
}Scope requirements
Scope requirements
最終更新日 2026年4月10日
⌘I