Konnect scorecards

Uses: Catalog
Related Documentation
Incompatible with
on-prem

A Catalog scorecard helps you evaluate services based on validation criteria. Scorecards help you detect issues, like whether there are services in the catalog that don’t have an on-call engineer assigned, or if you have GitHub repositories with stale pull requests that aren’t getting reviewed or closed.

From the scorecard view, you can view details on either a per-service or per-criteria basis.

You can use a prebuilt scorecard template that includes criteria from Kong and industry best practices, or design your own scorecard from scratch. You can also mix both approaches by starting out with a template and adding criteria to fit your needs.

Scorecard templates

Konnect provides several scorecard templates to help ensure your Catalog services adhere to industry best practices.

Scorecard template

Description

Service documentation Hosts your documentation files and API specs.
Service maturity Measures performance reflecting industry-defined DORA metrics: deployment frequency, lead time for changes, change failure rate, and time to restore service.
Kong best practices Best practices that we encourage users to follow when using other Konnect applications.
Security and compliance Checks that services are protected through external monitoring and vulnerability management tools.

Create a scorecard

To enable a scorecard on a service:

Service documentation linting

The service documentation template supports the following Spectral recipes:

Category

Description

Recipe rules

OAS Recommended Uses Stoplight’s style guide. Only considers criteria tagged with "recommended: true". Stoplight Style Guide
OWASP Top 10 Set of rules to check for OWASP security guidelines OWASP Top 10 API Security Guide
URL Versioning Set of rules to check for versioning API Versioning Guide
Documentation Set of rules to check for documentation best practices API Documentation Guidelines

Custom scorecard criteria

You can add criteria to a custom scorecard or a scorecard template. These allow you to further customize your scorecards.

You can list all available criteria by sending a GET request to the /criteria-templates endpoint:

curl -X GET "https://us.api.konghq.com/v1/criteria-templates" \
     --no-progress-meter --fail-with-body  \
     -H "Authorization: Bearer $KONNECT_TOKEN"

The following table details the different criteria you can specify:

Criteria

Description

Gateway Service Error Rate Ensures gateway error rate stays below a defined threshold over a selected time window.
Gateway Service Response Latency Ensures gateway response latency stays below a defined threshold over a selected time window.
Gateway Service Has Plugin Ensures all mapped Gateway Service resources have at least one Plugin installed from the selected category.
Has API Specs Ensures the service has the required number of API specifications attached.
Has Service Docs Ensures the service has the required number of documentation files attached.
Lint API Specs Ensures all attached API specifications pass selected lint rulesets.
Has Resources Ensures the service has the required number of mapped resources of the specified type.
Incident Limit Ensures the number of triggered incidents stays below a defined threshold over a selected time window.
On Call Engineer Assigned Ensures an on-call engineer is assigned to the service.
PagerDuty Service status is enabled Ensures the service has a PagerDuty resource mapped that has the active status.
Time Before Failure Ensures time between failures exceeds a minimum threshold over a selected time window.
Time to Acknowledge Ensures time to acknowledge incidents stays below a maximum threshold over a selected time window.
Time to Restore Ensures time to restore the service stays below a maximum threshold over a selected time window.
Minimum Pull Request Approving Reviews Ensures all merged PRs have at least the required number of approving reviews.
Stale Pull Request Limit Ensures the number of open PRs older than a defined age stays below the specified threshold.
Time to Approve Pull Request Ensures PRs are approved within a defined threshold over a selected time window.
Time to Merge Ensures PRs are merged within a defined threshold over a selected time window.
Time to Workflow Completion Ensures CI workflow runs complete within a defined threshold over a selected time window.
Open Vulnerability Limit Ensures the number of Dependabot-detected open vulnerabilities higher than the selected severity stays below the defined threshold.
Something wrong?

Help us make these docs great!

Kong Developer docs are open source. If you find these useful and want to make them better, contribute today!