giip

GitHub Actions Management API Guide (v1.2)

The GIIP platform provides APIs for managing and monitoring the workflow execution history of GitHub repositories.

🔌 Go to GitHub Integration Feature →

📋 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: githubToken must 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 text command and jsondata parameter substitution feature to securely manage workflow query conditions (perPage, status, etc.) at the code level.

Troubleshooting

SymptomCauseResolution
401 authentication error returnedMissing common x-giip-ak / x-giip-sk headersVerify both authentication headers are included.
Workflow execution history is emptyMissing/invalid gcId or insufficient githubToken scopeSpecify a valid gcId and grant the PAT Actions/repo read scope.
GitHubConfigCreate failsTypo in repoOwner/repoName or expired/invalid githubTokenVerify the repository info and use a valid PAT (Classic/Fine-grained).
RstVal error or jsondata parsing failurejsondata JSON escaping/encoding errorSend 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: