gd_api: General Glassdoor API function

Description Usage Arguments Value Examples

View source: R/gdoor.R

Description

General Glassdoor API function

Usage

1
2
3
gd_api(query = NULL, action = NULL, agent = gd_user_agent(),
  version = 1, format = "json", url = gd_url(), pid = gd_pid(),
  pat = gd_pat(), ip_address = NULL, add_query = NULL, ...)

Arguments

query

Additional options to pass to the query other than those specified here

action

The particular API call that you would like to make

agent

The User-Agent (browser) of the end user to whom the API results will be shown. Note that you can can obtain this from the "User-Agent" HTTP request header from the end-user

version

The API version. The current version is 1 except for jobs, which is currently version 1.1

format

Either xml or json as you prefer

url

Glassdoor RESTful API URL

pid

Your partner id, as assigned by Glassdoor

pat

Your partner key, as assigned by Glassdoor

ip_address

The IP address of the end user to whom the API results will be shown

add_query

Additional options to pass to the query other than those specified here (named list)

...

Additional options to send to GET

Value

A list of class gd_api

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
if (have_gd_pid() && have_gd_pat()) {
res = gd_api(
action = "employers",
other = NULL,
  version = 1,
format = "json",
query =  "pharmaceuticals")

res = gd_api(
action = "employers",
other = NULL,
 version = 1,
format = "json",
query = "pharmaceuticals", config = list())
}

Example output



glassdoor documentation built on May 2, 2019, 11:12 a.m.