项目作者: tumblbug

项目描述 :
Gatsby source plugin for loading job openings from Workable
高级语言: JavaScript
项目地址: git://github.com/tumblbug/gatsby-source-workable.git
创建时间: 2017-08-29T02:30:52Z
项目社区:https://github.com/tumblbug/gatsby-source-workable

开源协议:MIT License

下载


gatsby-source-workable

Loads job openings from Workable into Gatsby.js

Installation

  1. npm install gatsby-source-workable

Usage

To use this source you need to supply a Workable API key and your Workable subdomain. You can create a Workable API key by logging into Workable and going to Integrations > Access Token. You can see your subdomain by logging into your Workable backend and checking the URL, e.g. mycompany.workable.com.

Next, edit gatsby-config.js to use the plugin:

  1. {
  2. ...
  3. plugins: [
  4. ...
  5. {
  6. resolve: 'gatsby-source-workable',
  7. options: {
  8. subdomain: 'mycompany',
  9. apiKey: 'abc-123',
  10. fetchJobDetails: true // optional
  11. },
  12. },
  13. ]
  14. }

By default, gatsby-source-workable will only retrieve job openings that are published. To change this behavior, you can also supply an optional queryParams parameter inside of options. Possible query parameters are detailed in Workable’s API Documentation.

If you need more detailed information for each job opening you can also enable fetchJobDetails in options. This will make one additional API call per opening, providing all the information detailed here.

Querying

You can query the nodes created by the plugin as follows:

  1. {
  2. allWorkableJob {
  3. edges {
  4. node {
  5. ...
  6. }
  7. }
  8. }
  9. }

Detailed field descriptions are also available on Workable’s API Documentation.