Skip to main content

companies

Creates, updates, deletes, gets or lists a companies resource.

Overview

Namecompanies
TypeResource
Idgoogle.jobs.companies

Fields

NameDatatypeDescription
namestringRequired during company update. The resource name for a company. This is generated by the service when a company is created. The format is "projects/{project_id}/tenants/{tenant_id}/companies/{company_id}", for example, "projects/foo/tenants/bar/companies/baz".
careerSiteUristringThe URI to employer's career site or careers page on the employer's web site, for example, "https://careers.google.com".
derivedInfoobjectDerived details about the company.
displayNamestringRequired. The display name of the company, for example, "Google LLC".
eeoTextstringEqual Employment Opportunity legal disclaimer text to be associated with all jobs, and typically to be displayed in all roles. The maximum number of allowed characters is 500.
externalIdstringRequired. Client side company identifier, used to uniquely identify the company. The maximum number of allowed characters is 255.
headquartersAddressstringThe street address of the company's main headquarters, which may be different from the job location. The service attempts to geolocate the provided address, and populates a more specific location wherever possible in DerivedInfo.headquarters_location.
hiringAgencybooleanSet to true if it is the hiring agency that post jobs for other employers. Defaults to false if not provided.
imageUristringA URI that hosts the employer's company logo.
keywordSearchableJobCustomAttributesarrayThis field is deprecated. Please set the searchability of the custom attribute in the Job.custom_attributes going forward. A list of keys of filterable Job.custom_attributes, whose corresponding string_values are used in keyword searches. Jobs with string_values under these specified field keys are returned if any of the values match the search keyword. Custom field values with parenthesis, brackets and special symbols are not searchable as-is, and those keyword queries must be surrounded by quotes.
sizestringThe employer's company size.
suspendedbooleanOutput only. Indicates whether a company is flagged to be suspended from public availability by the service when job content appears suspicious, abusive, or spammy.
websiteUristringThe URI representing the company's primary web site or home page, for example, "https://www.google.com". The maximum number of allowed characters is 255.

Methods

NameAccessible byRequired ParamsDescription
getSELECTcompaniesId, projectsId, tenantsIdRetrieves specified company.
listSELECTprojectsId, tenantsIdLists all companies associated with the project.
createINSERTprojectsId, tenantsIdCreates a new company entity.
deleteDELETEcompaniesId, projectsId, tenantsIdDeletes specified company. Prerequisite: The company has no jobs associated with it.
patchUPDATEcompaniesId, projectsId, tenantsIdUpdates specified company.

SELECT examples

Lists all companies associated with the project.

SELECT
name,
careerSiteUri,
derivedInfo,
displayName,
eeoText,
externalId,
headquartersAddress,
hiringAgency,
imageUri,
keywordSearchableJobCustomAttributes,
size,
suspended,
websiteUri
FROM google.jobs.companies
WHERE projectsId = '{{ projectsId }}'
AND tenantsId = '{{ tenantsId }}';

INSERT example

Use the following StackQL query and manifest file to create a new companies resource.

/*+ create */
INSERT INTO google.jobs.companies (
projectsId,
tenantsId,
name,
displayName,
externalId,
size,
headquartersAddress,
hiringAgency,
eeoText,
websiteUri,
careerSiteUri,
imageUri,
keywordSearchableJobCustomAttributes
)
SELECT
'{{ projectsId }}',
'{{ tenantsId }}',
'{{ name }}',
'{{ displayName }}',
'{{ externalId }}',
'{{ size }}',
'{{ headquartersAddress }}',
{{ hiringAgency }},
'{{ eeoText }}',
'{{ websiteUri }}',
'{{ careerSiteUri }}',
'{{ imageUri }}',
'{{ keywordSearchableJobCustomAttributes }}'
;

UPDATE example

Updates a companies resource.

/*+ update */
UPDATE google.jobs.companies
SET
name = '{{ name }}',
displayName = '{{ displayName }}',
externalId = '{{ externalId }}',
size = '{{ size }}',
headquartersAddress = '{{ headquartersAddress }}',
hiringAgency = true|false,
eeoText = '{{ eeoText }}',
websiteUri = '{{ websiteUri }}',
careerSiteUri = '{{ careerSiteUri }}',
imageUri = '{{ imageUri }}',
keywordSearchableJobCustomAttributes = '{{ keywordSearchableJobCustomAttributes }}'
WHERE
companiesId = '{{ companiesId }}'
AND projectsId = '{{ projectsId }}'
AND tenantsId = '{{ tenantsId }}';

DELETE example

Deletes the specified companies resource.

/*+ delete */
DELETE FROM google.jobs.companies
WHERE companiesId = '{{ companiesId }}'
AND projectsId = '{{ projectsId }}'
AND tenantsId = '{{ tenantsId }}';