GitHub Actions Management API Guide (v1.2)
The GIIP platform provides APIs for managing and monitoring the workflow execution history of GitHub repositories.
📋 Overview
The GitHub Actions Management API synchronizes the latest workflow statuses of registered repositories and provides data so that failures can be checked immediately on the GIIP console.
🔐 Authentication & Security
- Header: Common x-giip-ak / x-giip-sk headers required.
- Token:
githubTokenmust be a GitHub Personal Access Token (Classic or Fine-grained).
📡 API Details (Sk3)
1. Retrieve GitHub Configuration List (GitHubConfigsList)
- Command:
text=GitHubConfigsList - jsondata:
{"csn": 123}(Optional) - Description: Returns GitHub integration configuration information by project.
2. Create GitHub Configuration (GitHubConfigCreate)
- Command:
text=GitHubConfigCreate - jsondata:
{
"csn": 123,
"configName": "Backend Repo",
"repoOwner": "org-name-or-user",
"repoName": "repo-name",
"githubToken": "ghp_..."
}
3. Retrieve Workflow Execution History (GitHubWorkflowRunsList)
- Command:
text=GitHubWorkflowRunsList - jsondata:
{"gcId": 123, "perPage": 20, "status": "all"} - Description: Retrieves GitHub Actions execution history for a specific integration configuration (gcId).
🛡️ Using Sk3 (High-fidelity Logging)
The giipApiSk3 endpoint is recommended for creating configurations that handle sensitive information like GitHub Personal Access Tokens and for workflow synchronization tasks.
- Endpoint:
https://giipfaw.azurewebsites.net/api/giipApiSk3 - Security Advantages: Automatically records leakage attempts or abnormal call patterns of
githubToken, and provides a detailed context (Stacktrace) upon errors for quick response. - Usage Tip: Use the
textcommand andjsondataparameter substitution feature to securely manage workflow query conditions (perPage, status, etc.) at the code level.
Troubleshooting
| Symptom | Cause | Resolution |
|---|---|---|
| 401 authentication error returned | Missing common x-giip-ak / x-giip-sk headers | Verify both authentication headers are included. |
| Workflow execution history is empty | Missing/invalid gcId or insufficient githubToken scope | Specify a valid gcId and grant the PAT Actions/repo read scope. |
GitHubConfigCreate fails | Typo in repoOwner/repoName or expired/invalid githubToken | Verify the repository info and use a valid PAT (Classic/Fine-grained). |
RstVal error or jsondata parsing failure | jsondata JSON escaping/encoding error | Send jsondata as valid JSON and check the API Result Codes Guide. |
Version: 1.3
Last Updated: 2026-04-11
Source: giipv3/public/help/api-github.en.md
Related Documents: