---
updatedAt: 2026-05-15T17:35:57.000Z
agentTools:
  projectIndex: https://developer.greenshades.com/llms.txt
---

# Get a position by its code.

# OpenAPI definition

```json
{
  "openapi": "3.0.1",
  "info": {
    "title": "Greenshades API",
    "description": "A public API for use by partners and clients of Greenshades Software",
    "termsOfService": "about:blank",
    "license": {
      "name": "Apache 2.0",
      "url": "http://www.apache.org/licenses/LICENSE-2.0.html"
    },
    "version": "1.0.0",
    "contact": {
      "name": "Greenshades Development",
      "url": "https://www.greenshades.com",
      "email": "development@greenshades.com"
    }
  },
  "servers": [
    {
      "url": "https://api.greenshadesonline.com"
    }
  ],
  "tags": [
    {
      "name": "Positions",
      "description": "Setup and management of company positions."
    }
  ],
  "paths": {
    "/positions/{positionCode}": {
      "get": {
        "operationId": "getPosition",
        "summary": "Get a position by its code.",
        "parameters": [
          {
            "name": "workspaceId",
            "in": "query",
            "description": "Results are filtered by workspace Id",
            "required": true,
            "schema": {
              "type": "integer"
            }
          },
          {
            "name": "positionCode",
            "in": "path",
            "description": "The position to retrieve.",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "security": [
          {
            "OAuth2": [
              "GO.Api.read",
              "GO.Api.full_access",
              "GO.Api.COR.read",
              "GO.Api.COR.full_access"
            ]
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Position"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/Position"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "*/*": {
                "schema": {
                  "type": "string",
                  "example": "Auth token is missing or invalid."
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "*/*": {
                "schema": {
                  "type": "string",
                  "example": "Position not found."
                }
              }
            }
          }
        },
        "tags": [
          "Positions"
        ]
      }
    }
  },
  "components": {
    "schemas": {
      "BaseCodeDescription": {
        "type": "object",
        "properties": {
          "code": {
            "type": "string",
            "description": "Unique code for identifying the entity",
            "nullable": false,
            "maxLength": 50
          },
          "description": {
            "type": "string",
            "maxLength": 100
          }
        }
      },
      "Position": {
        "allOf": [
          {
            "$ref": "#/components/schemas/BaseCodeDescription"
          },
          {
            "type": "object"
          },
          {
            "properties": {
              "occupationalCode": {
                "type": "string",
                "maxLength": 50
              },
              "workersCompMappings": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "stateAbbreviation": {
                      "type": "string",
                      "maxLength": 4,
                      "nullable": true,
                      "example": "FL"
                    },
                    "workersCompCode": {
                      "type": "string",
                      "maxLength": 100,
                      "example": "0034",
                      "nullable": true
                    },
                    "rate": {
                      "type": "number",
                      "nullable": true,
                      "example": 0.01
                    },
                    "effectiveDate": {
                      "type": "string",
                      "format": "date",
                      "nullable": true,
                      "example": "2023-05-25T00:00:00"
                    }
                  }
                }
              }
            }
          }
        ]
      }
    },
    "securitySchemes": {
      "OAuth2": {
        "type": "oauth2",
        "flows": {
          "clientCredentials": {
            "scopes": {
              "GO.Api.full_access": "Universal API read/write access",
              "GO.Api.read": "Universal API read-Only access",
              "GO.Api.write": "Universal API write-Only access",
              "GO.Api.COR.full_access": "Read/write access to the core API.",
              "GO.Api.COR.read": "Read-only access to the core API.",
              "GO.Api.COR.write": "Write-only access to the core API.",
              "GO.Api.BFT.EmployeeElections.full_access": "Read/write access for benefit elections.",
              "GO.Api.BFT.EmployeeElections.read": "Read-only access for benefit elections.",
              "GO.Api.BFT.EmployeeElections.write": "Write-only access for benefit elections.",
              "GO.Api.PAY.Setup.full_access": "Read/write access for payroll setup",
              "GO.Api.PAY.Setup.read": "Read-only access for payroll setup",
              "GO.Api.PAY.Setup.write": "Write-only access for payroll setup",
              "GO.Api.PAY.PayRuns.full_access": "Read/write access to payroll pay runs",
              "GO.Api.PAY.PayRuns.read": "Read-only access to payroll pay runs",
              "GO.Api.PAY.PayRuns.write": "Write-only access to payroll pay runs",
              "GO.Api.PAY.PaySchedules.full_access": "Read/write access to payroll pay schedules",
              "GO.Api.PAY.PaySchedules.read": "Read-only access to payroll pay schedules",
              "GO.Api.PAY.PaySchedules.write": "Write-only access to payroll pay schedules",
              "GO.Api.PAY.EmployeeCodes.full_access": "Read/write access to employee payroll code assignments",
              "GO.Api.PAY.EmployeeCodes.read": "Read-only access to employee payroll code assignments",
              "GO.Api.PAY.EmployeeCodes.write": "Write-only access to employee payroll code assignments",
              "GO.Api.PAY.EmployeeDirectDeposit.full_access": "Read/write access to employee direct deposit settings",
              "GO.Api.PAY.EmployeeDirectDeposit.read": "Read-only access to employee direct deposit settings",
              "GO.Api.PAY.EmployeeDirectDeposit.write": "Write-only access to employee direct deposit settings",
              "GO.Api.PAY.EmployeePayrollPaySchedules.full_access": "Read/write access to employees' payroll pay schedule settings.",
              "GO.Api.PAY.EmployeePayrollPaySchedules.read": "Read-only access to employees' payroll pay schedule settings.",
              "GO.Api.PAY.EmployeePayrollPaySchedules.write": "Write-only access to employees' payroll pay schedule settings.",
              "GO.Api.PAY.EmployeePayrollTaxes.full_access": "Read/write access to employees' payroll tax settings.",
              "GO.Api.PAY.EmployeePayrollTaxes.read": "Read-only access to employees' payroll tax settings.",
              "GO.Api.PAY.EmployeePayrollTaxes.write": "Write-only access to employees' payroll tax settings.",
              "GO.Api.PAY.Reporting.read": "Access to payroll reports.",
              "GO.Api.WEBHOOK.full_access": "Read/write access to webhook event subscriptions",
              "GO.Api.WEBHOOK.read": "Read-only access to webhook event subscriptions",
              "GO.Api.WEBHOOK.write": "Write-only access to webhook event subscriptions"
            },
            "tokenUrl": "https://auth.greenshadesonline.com/connect/token",
            "refreshUrl": "https://auth.greenshadesonline.com/connect/token"
          }
        },
        "description": ""
      }
    }
  },
  "x-readme": {
    "explorer-enabled": true,
    "proxy-enabled": true,
    "samples-enabled": true
  }
}
```