API Reference

The Companies API is organized around REST. Our API has predictable resource-oriented URLs, accepts form-encoded request bodies, returns JSON-encoded responses, and uses standard HTTP response codes, authentication, and verbs.

You can view code examples in the area to the right, and you can switch the programming language of the examples with the tabs in the top right. We provide examples in Curl, Ruby, PHP, Java - and for Events, JavaScript.

Need help?

Message us in the chatbox. A developer will reply under 1 hour to see how we can solve your issue.

Not a developer?

We can help you integrate our API. Send us a message in the chatbox.

Base URL
https://api.thecompaniesapi.com

Authentication

The Companies API uses API token to authenticate requests. You can manage your API tokens in your settings.

Your API tokens carry many privileges , so be sure to keep them secure! Do not share them in publicly accessible areas such as GitHub, client-side code, and so forth. Those authentication keys are permanent (they never expire). You can consider them safe for long-term purposes.

All API requests must be made over HTTPS. Calls made over plain HTTP will fail. API requests without authentication will also fail.

There are two ways to authenticate your HTTP requests to the API:

- By adding an Authorization header. The Authorization header is formatted as such: Authorization: Basic MY-API-TOKEN (replace MY-API-TOKEN with one of yours).

- By sending the API token as a GET parameter: ?token=MY-API-TOKEN (mostly used for quick testing).

Your API tokens
Your API token is included in all the examples here, so you can test any example right away. Only you can see this value.

Errors

The Companies API uses conventional HTTP response codes to indicate the success or failure of an API request. In general: Codes in the 2xx range indicate success. Codes in the 4xx range indicate an error that failed given the information provided (e.g., a required parameter was omitted, a charge failed, etc.). Codes in the 5xx range indicate an error with The Companies API's servers (these are rare).

Some 4xx errors that could be handled programmatically (e.g., a parameter is missing) include an error code that briefly explains the error reported.

Attributes

error. code string
For some errors that could be handled programmatically, a short string indicating the error code reported. 403
error. message string
A human-readable message providing more details about the error. For card errors, these messages can be shown to your users. Missing api token
error. param string
If the error is parameter-specific, the parameter related to the error. For example, you can use this to display a message near the correct form field. The Company domain is not a string
error. type enum
The type of error returned. apiConnectionError
Possible values apiConnectionError apiError authenticationError invalidRequestError noCreditsRemaining rateLimitError
HTTP status code summary
200 - OK 500, 502, 503, 504 - Server Errors
400 - Bad Request The request was unacceptable, often due to missing a required parameter.
401 - Unauthorized No valid API token provided.
402 - Request Failed The parameters were valid but the request failed.
403 - Forbidden The API token doesn't have permissions to perform the request.
404 - Not Found The requested resource doesn't exist.
409 - Conflict The request conflicts with another request (perhaps due to using the same idempotent key).
429 - Too Many Requests Too many requests hit the API too quickly. We recommend an exponential backoff of your requests.
500, 502, 503, 504 - Server Errors Something went wrong on The Companies API's end. (These are rare.)
HTTP status code summary
apiConnectionError Failure to connect to The Companies API.
apiError API errors cover any other type of problem (e.g., a temporary problem with The Companies API's servers), and are extremely uncommon.
authenticationError Failure to properly authenticate yourself in the request.
invalidRequestError Invalid request errors arise when your request has invalid parameters.
noCreditsRemaining You have no remaining credits to make this request.
rateLimitError Too many requests hit the API too quickly.

Companies

If you need additional endpoints, feel free to reach us in the chatbox. We are usually fast to implement them.

Available Endpoints
GET https://api.thecompaniesapi.com/v1/companies
GET https://api.thecompaniesapi.com/v1/companies/:domain
GET https://api.thecompaniesapi.com/v1/companies/by-name/:name
GET https://api.thecompaniesapi.com/v1/companies/:domain/email-patterns

Search companies by name
1 credit

Retrieve the company profile information by providing its name. We have more than 50 data points including the industries, the revenue, the technologies…

Query parameters

name required
The company name. …/companies/by-name/amazon
size optional
The number of companies to be returned (between 1 and 5). Default to 1. …/companies/by-name/amazon?size=2

Response

Returns an array containing the companies that match with the name. When no companies match, an empty array will be returned. Make sure to handle this case in your code. Also, use something like encodeURI() to encode the name property properly.

Attributes

data array
The companies that match with the name.
Show child attributes
metas array
The metas information.
Show child attributes
Endpoint
GET https://api.thecompaniesapi.com/v1/companies/by-name/amazon
Response
Copy
{ data : [ { alexaRank : 9 , analyzedAt : "2022-02-10T23:46:59.000Z" , businessType : "privately-held" , city : { }, codeNaics : null , codeSic : null , continent : { }, country : { }, county : { }, description : "Amazon strives to be Earth's most customer-centric company where people can find and discover virtually anything they want to buy online. By giving customers more of what they want - low prices, vast selection, and convenience - Amazon continues to grow and evolve as a world-class e-commerce platform.\\Founded by Jeff Bezos, the Amazon.com website started in 1995 as a place to buy books because of the unique customer experience the Web could offer book lovers. Bezos believed that only the Internet could offer customers the convenience of browsing a selection of millions of book titles in a single sitting. During the first 30 days of business, Amazon fulfilled orders for customers in 50 states and 45 countries - all shipped from his Seattle-area garage.\\Amazon's evolution from Web site to e-commerce partner to development platform is driven by the spirit of innovation that is part of the company's DNA. The world's brightest technology minds come to Amazon.com to research and develop technology that improves the lives of shoppers and sellers around the world." , descriptionShort : "Amazon strives to be Earth's most customer-centric company where people can find and discover virtually anything they want to buy online." , domain : "amazon.com" , domainAlts : [ ] , domainName : "amazon" , domainTld : "com" , emailPatterns : [ ], id : 5130216 , industries : [ ], industryMain : "e-commerce" , logo : "https://poweredwith.nyc3.cdn.digitaloceanspaces.com/images/companies/amazon.com.jpg" , monthlyVisitors : "over-1b" , name : "Amazon" , phoneNumber : "(206) 266-1000" , revenue : "over-1b" , similar : [ ], socialNetworks : { }, state : { }, technologies : [ ], technologyCategories : [ ], totalEmployees : "over-10k" , yearFounded : 1994 , } , ] , meta : { currentPage : 1 , firstPage : 1 , firstPageUrl : null , lastPage : 848 , lastPageUrl : null , nextPageUrl : null , perPage : 1 , previousPageUrl : null , total : 848 , } , }

Find a company by domain name
1 credit

Retrieve the company profile information by providing a domain name. We have more than 50 data points including the industries, the revenue, the technologies…

Query parameters

domain required
The company domain. …/companies/amazon.com

Response

Returns a company with all the information for the provided domain name. When no company matches, a 404 responses will be returned. Make sure to handle this case in your code.

Attributes

company. alexaRank number
The company's Alexa rank. 8
company. analyzedAt string
The last time the company has been analyzed. 2021-12-22T15:49:15.000Z
company. businessType string
The company's business type. public-company
Possible values educational-institution government-agency nonprofit partnership privately-held public-company self-employed sole-proprietorship
company. city object
The company's city.
Show child attributes
company. codeNaics string
The company's code NAICS. 518210
company. codeSic string
The company's code SIC. 5961
company. continent object
The company's continent.
Show child attributes
company. county object
The company's county.
Show child attributes
company. country object
The company's country.
Show child attributes
company. description string
The company's description. Amazon.com, Inc. is an American multinational technology company based in Seattle, Washington, which focuses on…
company. descriptionShort string
The company's short description in one line. Amazon.com, Inc. is an American multinational technology company based in Seattle.
company. domain string
The company's domain. amazon.com
company. domainAlts string
The company's alternative domains (redirection).
company. domainName string
The company's domain name. amazon
company. domainTld string
The company's top level domain. com
company. emailPatterns array
The company's email patterns for employees.
Show child attributes
company. id number
The company id. 5130216
company. industries array
The company's industries. Internet, Fashion, Marketing…
company. industryMain string
The company's main industry. Internet
company. logo string
The company's logo url. https://poweredwith.nyc3.cdn.digitaloceanspaces.com/images/companies/a2a8283864386ca04a5694e8b58759e6.jpg
company. monthlyVisitors enum
The company's total monthly visitors. over-1b
Possible values under-10k 10k-50k 50k-100k 100k-500k 500k-1m 1m-10m 10m-50m 50m-100m 100m-500m 500m-1b over-1b
company. name string
The company's name. Amazon
company. phoneNumber string
The company's phone number. 00 1 206-922-0880
company. revenue enum
The company's revenue. over-1b
Possible values under-1m 1m-10m 10m-50m 50m-100m 100m-200m 200m-1b over-1b
company. similar array
The similar companies.
Show child attributes
company. socialNetworks object
The company's social networks.
Show child attributes
company. state object
The company's state.
Show child attributes
company. stockExchange string
The company's stock exchange. NYSE
company. stockSymbol string
The company's stock symbol. AMZN
company. technologies array
The company's technologies.
company. technologyCategories array
The company's categories of technologies.
company. totalEmployees enum
The company's total number of employees. over-10k
Possible values 1-10 10-50 50-200 200-500 500-1k 1k-5k 5k-10k over-10k
company. totalEmployeesExact number
The company's exact number of employees. 3930
company. yearFounded number
The company's year of foundation. 1994
Endpoint
GET https://api.thecompaniesapi.com/v1/companies/amazon.com
Response
Copy
{ alexaRank : 9 , analyzedAt : "2022-02-10T23:46:59.000Z" , businessType : "privately-held" , city : { }, codeNaics : null , codeSic : null , continent : { }, country : { }, county : { }, description : "Amazon strives to be Earth's most customer-centric company where people can find and discover virtually anything they want to buy online. By giving customers more of what they want - low prices, vast selection, and convenience - Amazon continues to grow and evolve as a world-class e-commerce platform.\\Founded by Jeff Bezos, the Amazon.com website started in 1995 as a place to buy books because of the unique customer experience the Web could offer book lovers. Bezos believed that only the Internet could offer customers the convenience of browsing a selection of millions of book titles in a single sitting. During the first 30 days of business, Amazon fulfilled orders for customers in 50 states and 45 countries - all shipped from his Seattle-area garage.\\Amazon's evolution from Web site to e-commerce partner to development platform is driven by the spirit of innovation that is part of the company's DNA. The world's brightest technology minds come to Amazon.com to research and develop technology that improves the lives of shoppers and sellers around the world." , descriptionShort : "Amazon strives to be Earth's most customer-centric company where people can find and discover virtually anything they want to buy online." , domain : "amazon.com" , domainAlts : [ ] , domainName : "amazon" , domainTld : "com" , emailPatterns : [ ], id : 5130216 , industries : [ ], industryMain : "e-commerce" , logo : "https://poweredwith.nyc3.cdn.digitaloceanspaces.com/images/companies/amazon.com.jpg" , monthlyVisitors : "over-1b" , name : "Amazon" , phoneNumber : "(206) 266-1000" , revenue : "over-1b" , similar : [ ], socialNetworks : { }, state : { }, technologies : [ ], technologyCategories : [ ], totalEmployees : "over-10k" , yearFounded : 1994 , }

Fetch similar companies
5 credits

Fetch similar companies for a list of domains.

Query parameters

domains
A list of domains separated by commas. …/companies/similar?domains[]=amazon.com&domains[]=wix.com
page optional
The page to fetch (default to 1). …/companies/similar?domains[]=…&page=1
size optional
The number of similar companies to be returned (between 1 and 50). Default to 10. …/companies/similar?domains[]=…&size=50

Response

Returns a paginated response including the similar companies for your list of domains. When no results can be found, the data property will be an empty array.

Attributes

data array
The similar companies for your list of domains.
Show child attributes
metas array
The metas information.
Show child attributes
Endpoint
GET https://api.thecompaniesapi.com/v1/companies/similar?domains[]=…&page=1&size=10
Response
Copy
{ data : [ { alexaRank : 20 , analyzedAt : "2022-02-10T23:46:59.000Z" , businessType : null , city : { }, codeNaics : "511210" , codeSic : "7372" , continent : { }, country : { }, county : { }, description : "At Microsoft, our mission is to empower every person and every organization on the planet to achieve more. Our mission is grounded in both the world in which we live and the future we strive to create. Today, we live in a mobile-first, cloud-first world, and the transformation we are driving across our businesses is designed to enable Microsoft and our customers to thrive in this world. \\We do business in 170 countries and are made up of 114,000 passionate employees dedicated to fulfilling our mission of helping you and your organization achieve more.\" , domain : "microsoft.com" , domainAlts : [ ] , domainName : "microsoft" , domainTld : "com" , emailPatterns : [ ], id : 5130232 , industries : [ ], industryMain : "software" , logo : "https://poweredwith.nyc3.cdn.digitaloceanspaces.com/images/companies/microsoft.com.jpg" , monthlyVisitors : "over-1b" , name : "Microsoft" , phoneNumber : "(503) 443-7070" , revenue : "over-1b" , similarDomains : [ ], similitude : 100 , socialNetworks : { }, state : { }, technologies : [ ], technologyCategories : [ ], totalEmployees : "over-10k" , yearFounded : 1975 , } , { alexaRank : 104 , analyzedAt : "2022-02-10T23:52:36.000Z" , businessType : "privately-held" , city : { }, codeNaics : null , codeSic : null , continent : { }, country : { }, county : { }, description : "We're a diverse collection of thinkers and doers, continually reimagining what's possible to help us all do what we love in new ways. The people who work here have reinvented entire industries with the Mac, iPhone, iPad, and Apple Watch, as well as with services, including iTunes, the App Store, Apple Music, and Apple Pay. And the same passion for innovation that goes into our products also applies to our practices — strengthening our commitment to leave the world better than we found it." , domain : "apple.com" , domainAlts : [ ] , domainName : "apple" , domainTld : "com" , emailPatterns : [ ], id : 5130253 , industries : [ ], industryMain : "computers" , logo : "https://poweredwith.nyc3.cdn.digitaloceanspaces.com/images/companies/apple.com.jpg" , monthlyVisitors : "over-1b" , name : "Apple" , phoneNumber : "(408) 606-5775" , revenue : "over-1b" , similarDomains : [ ], similitude : 100 , socialNetworks : { }, state : { }, technologies : [ ], technologyCategories : [ ], totalEmployees : "over-10k" , yearFounded : 1976 , } , { alexaRank : 501 , analyzedAt : "2022-02-11T00:04:33.000Z" , businessType : null , city : { }, codeNaics : null , codeSic : null , continent : { }, country : { }, county : { }, description : "IBM is a global technology and innovation company headquartered in Armonk, NY. It is the largest technology and consulting employer in the world, with more than 375,000 employees serving clients in 170 countries. Just completing its 22nd year of patent leadership, IBM Research has defined the future of information technology with more than 3,000 researchers in 12 labs located across six continents. Scientists from IBM Research have produced six Nobel Laureates, 10 U.S. National Medals of Technology, five U.S. National Medals of Science, six Turing Awards, 19 inductees in the National Academy of Sciences and 20 inductees into the U.S. National Inventors Hall of Fame. Today, IBM is much more than a "hardware, software, services" company. IBM is now emerging as a cognitive solutions and cloud platform company. Our work and our people can be found in all sorts of interesting places. IBMers are helping transform healthcare, improving the retail shopping experience, rerouting traffic jams and even designing the next generation fan experience in sports stadiums around the world. It's the kind of thing we've been doing for more than 100 years.\\This is IBM's official LinkedIn account and it follows IBM Social Computing Guidelines. We reserve the right to delete comments that are offensive or suggestive, personal attacks, anonymous, wildly off-topic, spam or advertisements." , domain : "ibm.com" , domainAlts : [ ] , domainName : "ibm" , domainTld : "com" , emailPatterns : [ ], id : 6161279 , industries : [ ], industryMain : "software" , logo : null , monthlyVisitors : "500m-1b" , name : "IBM" , phoneNumber : "(800) 426-4968" , revenue : "10m-50m" , similarDomains : [ ], similitude : 100 , socialNetworks : { }, state : { }, technologies : [ ] , technologyCategories : [ ] , totalEmployees : "over-10k" , yearFounded : 1911 , } , { alexaRank : 3235 , analyzedAt : "2022-02-11T00:51:07.000Z" , businessType : null , city : { }, codeNaics : null , codeSic : null , continent : { }, country : { }, county : null , description : "Tata Consultancy Services is an IT services, consulting and business solutions organization that delivers real results to global business, ensuring a level of certainty no other firm can match. TCS offers a consulting-led, integrated portfolio of IT, BPS,infrastructure, engineering and assurance services. This is delivered through its unique Global Network Delivery Model™, recognized as the benchmark of excellence in software development. A part of the Tata group, India's largest industrial conglomerate, TCS has over 387,000 of the world's best-trained consultants in 45 countries. The company generated consolidated revenues of US $18.2 billion for year ended March 31, 2017 and is listed on the BSE Limited and National Stock Exchange of India Limited. For more information, visit us at www.tcs.com." , domain : "tcs.com" , domainAlts : [ ] , domainName : "tcs" , domainTld : "com" , emailPatterns : [ ], id : 4424 , industries : [ ], industryMain : "it-services" , logo : "https://poweredwith.nyc3.cdn.digitaloceanspaces.com/images/companies/tcs.com.jpg" , monthlyVisitors : "100m-500m" , name : "Tata Consultancy Services" , phoneNumber : "(646) 313-4594" , revenue : "over-1b" , similarDomains : [ ], similitude : 100 , socialNetworks : { }, state : { }, technologies : [ ], technologyCategories : [ ], totalEmployees : "over-10k" , yearFounded : 1968 , } , { alexaRank : 449 , analyzedAt : "2022-02-10T23:52:39.000Z" , businessType : null , city : { }, codeNaics : null , codeSic : null , continent : { }, country : { }, county : { }, description : "The Oracle Cloud offers complete SaaS application suites for ERP, HCM and CX, plus best-in-class database Platform as a Service (PaaS) and Infrastructure as a Service (IaaS) from data centers throughout the Americas, Europe and Asia. For more information about Oracle (NYSE:ORCL), please visit us at oracle.com." , domain : "oracle.com" , domainAlts : [ ] , domainName : "oracle" , domainTld : "com" , emailPatterns : [ ], id : 5130719 , industries : [ ], industryMain : "utilities" , logo : "https://poweredwith.nyc3.cdn.digitaloceanspaces.com/images/companies/oracle.com.jpg" , monthlyVisitors : "over-1b" , name : "Oracle" , phoneNumber : "(800) 633-0738" , revenue : "1m-10m" , similarDomains : [ ], similitude : 100 , socialNetworks : { }, state : { }, technologies : [ ], technologyCategories : [ ], totalEmployees : "over-10k" , yearFounded : 1977 , } , { alexaRank : 4442 , analyzedAt : "2021-12-14T10:13:58.000Z" , businessType : null , city : null , codeNaics : null , codeSic : null , continent : null , country : null , county : null , description : null , domain : "aboutamazon.com" , domainAlts : [ ] , domainName : "aboutamazon" , domainTld : "com" , emailPatterns : [ ] , id : 7235 , industries : [ ] , industryMain : null , logo : "https://poweredwith.nyc3.cdn.digitaloceanspaces.com/images/companies/aboutamazon.com.jpg" , monthlyVisitors : "100m-500m" , name : "Amazon" , phoneNumber : null , revenue : null , similarDomains : [ ], similitude : 100 , socialNetworks : { }, state : null , technologies : [ ], technologyCategories : [ ], totalEmployees : "over-10k" , yearFounded : 1994 , } , { alexaRank : null , analyzedAt : "2022-02-08T09:24:33.000Z" , businessType : null , city : null , codeNaics : null , codeSic : null , continent : null , country : null , county : null , description : null , domain : "goo.gle" , domainAlts : [ ] , domainName : "goo" , domainTld : "gle" , emailPatterns : [ ] , id : 14864595 , industries : [ ] , industryMain : null , logo : null , monthlyVisitors : "under-10k" , name : "Google" , phoneNumber : null , revenue : null , similarDomains : [ ], similitude : 100 , socialNetworks : { }, state : null , technologies : [ ] , technologyCategories : [ ] , totalEmployees : "over-10k" , yearFounded : 1998 , } , { alexaRank : null , analyzedAt : "2022-02-17T10:04:33.000Z" , businessType : null , city : { }, codeNaics : null , codeSic : null , continent : { }, country : { }, county : { }, description : "Cultura digital. Próximamente más información al respecto sobre la fecha de lanzamiento, partners, motivo y demás temas relacionados que puedan ser de interés.\Cultura digital. Próximamente más información al respecto sobre la fecha de lanzamiento, partners, motivo y demás temas relacionados que puedan ser de interés." , domain : "lektu.com" , domainAlts : [ ] , domainName : "lektu" , domainTld : "com" , emailPatterns : [ ] , id : 681538 , industries : [ ], industryMain : "e-commerce" , logo : "https://poweredwith.nyc3.cdn.digitaloceanspaces.com/images/companies/lektu.com.jpg" , monthlyVisitors : "under-10k" , name : "Lektu" , phoneNumber : null , revenue : null , similarDomains : [ ], similitude : "41.67" , socialNetworks : { }, state : { }, technologies : [ ], technologyCategories : [ ], totalEmployees : "1-10" , yearFounded : 2014 , } , { alexaRank : null , analyzedAt : "2021-12-16T11:28:53.000Z" , businessType : null , city : { }, codeNaics : null , codeSic : null , continent : { }, country : { }, county : { }, description : "MustBuy.co.za is an online retailer of products and services based in South Africa. Company has grown from physical store into the online retail business, one of the fastest growing branches of the economy in the world.\\We have launched an online shopping platform in 2012 with the intent to focus on:\\ - Online Marketplace that Suits Everyone – platform that will be easy to use by customers, retailers and affiliates alike. Flexibility, innovation and user friendliness are at the core of the platform.\ - Largest Offer at Most Competitive Prices – a special emphasis has been put on creating a comprehensive product and service offering which would satisfy the needs of even the most demanding shoppers and at the same maintain competitive pricing.\ - Customer at the Center of Everything – customer satisfaction and needs are not just a goal for MustBuy but rather at the center of our business model, where all products and services being developed by the company and offered to partners are inspired by our customers and tailored on their inputs.\\MustBuy currently offers millions of products to potential customers with just click, and promotes these three core values through all of our business activities. Beside a large variety of products and competitive prices we also provide flexible financing to customers, where they can receive instant approval for a monthly installment payments via Mobicred.\\For a unique shopping experience visit us @ www.mustbuy.co.za" , domain : "mustbuy.co.za" , domainAlts : [ ] , domainName : "mustbuy" , domainTld : "co.za" , emailPatterns : [ ], id : 10009204 , industries : [ ], industryMain : "e-commerce" , logo : null , monthlyVisitors : "under-10k" , name : "MustBuy.co.za" , phoneNumber : "+27 16 018 0071" , revenue : null , similarDomains : [ ], similitude : "41.67" , socialNetworks : { }, state : { }, technologies : [ ] , technologyCategories : [ ] , totalEmployees : "1-10" , yearFounded : 2011 , } , { alexaRank : 7164 , analyzedAt : "2022-02-11T00:39:27.000Z" , businessType : null , city : { }, codeNaics : "515120" , codeSic : "5961" , continent : { }, country : { }, county : { }, description : "HSN is a leading interactive entertainment and lifestyle retailer, offering a curated assortment of exclusive products and top brand names to its customers. HSN incorporates entertainment, inspiration, personalities and industry experts to provide an entirely unique shopping experience. At HSN, customers find exceptional selections in Health & Beauty, Jewelry, Home/Lifestyle, fashion/Accessories, and Electronics. HSN broadcasts live to 96 million households in the US in HD 24/7 and its website - hsn.com features more than 50,000 product videos. Mobile applications include HSN apps for iPad, iPhone and Android. HSN, founded 36 years ago as the first shopping network, is an operating segment of HSN, Inc. (Nasdaq: HSNI). For more information, please visit HSN.com, or follow @HSN on Facebook and Twitter." , domain : "hsn.com" , domainAlts : [ ] , domainName : "hsn" , domainTld : "com" , emailPatterns : [