rest-endpoints

Standardize OrangeHRM REST API v2 endpoint implementation and maintenance.

1.1k|746|Updated Jan 5, 2017
One-click install
npx skills add https://github.com/orangehrm/orangehrm --skill rest-endpoints
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: rest-endpoints
Source: https://github.com/orangehrm/orangehrm/tree/main/.agents/skills/rest-endpoints
Command: npx skills add https://github.com/orangehrm/orangehrm --skill rest-endpoints

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Developing OrangeHRM REST API v2 endpoints requires navigating complex framework conventions for routing, request validation, access control, and response formatting, which is time-consuming and error-prone for developers working on the OrangeHRM platform.

Core Features & Use Cases

  • Full Endpoint Lifecycle Guidance: Covers route definition in routes.yaml, Endpoint interface selection, request parameter handling, validation, error mapping, and response formatting.
  • Pattern Recipes & Checklists: Provides ready-to-use code recipes for common endpoint types (full CRUD, file upload, self-scoped endpoints, validation-only endpoints) and step-by-step checklists for adding new endpoints or debugging unexpected responses.
  • Use Cases: Use this skill when creating new REST endpoints for OrangeHRM plugins, editing existing API logic, debugging 4xx/5xx API responses, or learning how the OrangeHRM REST layer is wired together.

Quick Start

Use the rest-endpoints skill to implement a new CRUD API endpoint for the OrangeHRM recruitment module that supports creating, reading, updating, and deleting job vacancy records.

Frequently Asked Questions about rest-endpoints

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a new REST API endpoint in an OrangeHRM plugin?▼

To create an OrangeHRM REST API v2 endpoint, you define routes in routes.yaml, select the correct Endpoint interface, implement request parameter validation, map HTTP status codes, and enforce row-level access control.

What is the standard request lifecycle for OrangeHRM REST API v2 endpoints?▼

The OrangeHRM REST API v2 request lifecycle covers route definition, Endpoint interface selection, request parameter handling, validation, error mapping, and response formatting to ensure standardized API behavior.

How do I debug 4xx and 5xx API responses in OrangeHRM?▼

Debug OrangeHRM REST API 4xx and 5xx responses by checking request parameter validation rules, verifying HTTP status code mapping, and reviewing row-level access control enforcement using provided step-by-step checklists.

Does the OrangeHRM REST API support sorting, pagination, and filtering out of the box?▼

Yes, OrangeHRM REST API v2 endpoint implementation includes configuring sorting, pagination, and filtering parameters to ensure correct data retrieval and response formatting.

What patterns should I follow for file upload or self-scoped endpoints in OrangeHRM?▼

OrangeHRM REST API v2 provides ready-to-use code recipes for common endpoint types including full CRUD, file upload, self-scoped endpoints, and validation-only endpoints to maintain framework coding standards.

Why am I getting access control errors when calling my OrangeHRM API endpoint?▼

Access control errors in OrangeHRM REST API v2 endpoints occur when row-level access control enforcement is not properly configured, requiring validation of endpoint interface selection and access rules.