Website logo

Retrieve jobs categories

This is a convenience method that returns jobs categories from Trade Me Jobs.

URL: https://api.trademe.co.nz/v1/Categories/Jobs.{file_format}
HTTP Method: GET
Requires Authentication? No
Permission Required: Public
Supported Formats: XML, JSON
Rate Limited? No

URL parameters

file_format Enumeration (required) The format of the response.
xml Serialize responses into XML.
json Serialize responses into JSON.

Query String parameters

region Integer (optional)

The ID of the region used to filter listing counts. Only applicable if with_counts is true.

with_counts Boolean (optional)

Indicates whether to include the number of listings in each category. Defaults to false.

Returns

Collection of <JobCategory>

A category containing all job categories.

Name String or null

The name of the job category.

Code String or null

The code number of the job category.

SubCategories Collection of <JobCategory> or null

A list of subcategories.

(This type has already been defined)

Example XML Response (switch to JSON)

<JobCategories xmlns="http://api.trademe.co.nz/v1">
  <JobCategory>
    <Name>ABC</Name>
    <Code>ABC</Code>
    <SubCategories>
      <JobCategory />
      <JobCategory />
    </SubCategories>
  </JobCategory>
  <JobCategory>
    <Name>ABC</Name>
    <Code>ABC</Code>
    <SubCategories>
      <JobCategory />
      <JobCategory />
    </SubCategories>
  </JobCategory>
</JobCategories>

Example JSON Response (switch to XML)

[
  {
    "Name": "ABC",
    "Code": "ABC",
    "SubCategories": [
      {
      },
      {
      }
    ]
  },
  {
    "Name": "ABC",
    "Code": "ABC",
    "SubCategories": [
      {
      },
      {
      }
    ]
  }
]