Copy
## API Spec and Version
openapi: 3.0.0
# Service Descriptors
# Required fields: info, title, x-cortex-tag
info:
title: Payments API
x-cortex-tag: payments-api
description: Handles payment processing, refunds, and transaction history for the Cortex platform.
# Groups
# !Groups must contain only alphanumeric characters, and may not contain whitespaces!
x-cortex-groups:
- backend
- payments
- us-west
# Owners
x-cortex-owners:
- type: group
name: platform-engineering
provider: CORTEX # Use when referring to a team defined in Cortex; these teams do not map to identities from integrations
description: Core platform team responsible for payments infrastructure
- type: email
email: backend-oncall@cortex.io
description: On-call rotation for backend services
- type: group
name: cortexapps/backend-platform
provider: ACTIVE_DIRECTORY | AZURE_DEVOPS | BAMBOO_HR | GITHUB | GITLAB | GOOGLE | OKTA | OPSGENIE | SERVICE_NOW | WORKDAY
# Also see the team entity example below
# Links
x-cortex-link:
- name: API Reference
type: OPENAPI
url: https://api.cortex.io/payments/openapi.yaml
description: OpenAPI spec for the Payments API
- name: Runbook
type: DOCUMENTATION
url: https://cortex.atlassian.net/wiki/spaces/ENG/pages/payments-api-runbook
description: Operational runbook for incidents and deployments
## Note that type of OPENAPI/ASYNC_API will be displayed in the API Explorer tab in the Cortex UI
## Links support relative URLs
# Dashboards
x-cortex-dashboards:
embeds:
- type: datadog
url: https://app.datadoghq.com/dashboard/abc-123-xyz/payments-api-overview
# Custom Data
x-cortex-custom-metadata:
tier: tier-1
language:
value: go
description: Primary implementation language
pci-compliant:
value: true
description: Service is in scope for PCI DSS compliance
on-call-schedule:
- platform-engineering
- backend-sre
# Custom entities
# You cannot create a custom entity type via GitOps, but after creating the type in the UI or API, you can create custom entities via GitOps.
title: Alex Rivera
description: Senior Platform Engineer
x-cortex-tag: employee-alex-rivera
x-cortex-type: org-employees
x-cortex-definition:
location: San Francisco
department: Platform Engineering
# Parent and child relationships
x-cortex-type: team
x-cortex-children:
- tag: payments-frontend-team
- tag: payments-backend-team
x-cortex-type: domain
x-cortex-parents:
- tag: engineering-domain
- tag: fintech-domain
# Entity relationships
x-cortex-relationships:
- type: depends-on
destinations:
- tag: fraud-detection-service
- tag: ledger-service
# Dependencies
# Required fields: x-cortex-tag, method (required if path present), path (required if method present)
x-cortex-dependency:
- tag: fraud-detection-service
method: POST
path: /v1/evaluate
description: Evaluates transactions for fraud signals before processing
metadata:
tags:
- payments
- fraud
prod: true
# Team configurations
title: Platform Engineering
x-cortex-tag: platform-engineering
x-cortex-type: team
x-cortex-team:
groups:
- name: platform-engineering
provider: OKTA
members:
- name: Jordan Lee
email: jordan.lee@cortex.io
notificationsEnabled: true
- name: Samantha Dawson
email: samantha.dawson@cortex.io
notificationsEnabled: false
x-cortex-children:
- tag: infra-team
- tag: sre-team
# Domain configurations
x-cortex-type: domain
x-cortex-owners:
- type: GROUP
name: cortexapps/engineering
provider: GITHUB
inheritance: APPEND | FALLBACK | NONE
x-cortex-children:
- tag: payments-api
- tag: payments-database
# Integrations
# Apiiro
x-cortex-apiiro:
repositories:
- alias: payments-api
repositoryId: cortexapps-payments-api
- alias: payments-worker
repositoryId: cortexapps-payments-worker
applications:
- alias: payments-api-app
applicationId: app-payments-api-prod
- alias: payments-worker-app
applicationId: app-payments-worker-prod
# AWS Cloud Control types
x-cortex-infra:
aws:
cloudControl:
- type: AWS::RDS::DBInstance
region: us-west-2
accountId: "123456789012"
identifier: payments-db-prod
# AWS ECS
x-cortex-infra:
aws:
ecs:
- clusterArn: arn:aws:ecs:us-west-2:123456789012:cluster/prod-cluster
serviceArn: arn:aws:ecs:us-west-2:123456789012:service/prod-cluster/payments-api
- clusterArn: arn:aws:ecs:us-east-1:123456789012:cluster/prod-cluster-east
serviceArn: arn:aws:ecs:us-east-1:123456789012:service/prod-cluster-east/payments-api
# Azure DevOps
x-cortex-git:
azure:
project: cortex-platform
repository: payments-api
# Azure Resources
x-cortex-azure:
ids:
- id: /subscriptions/1fbb2da1-2ce7-45e4-b85f-676ab8e12345/resourceGroups/payments-prod/providers/Microsoft.Compute/disks/payments-db-disk
alias: payments-prod-disk # alias is optional and only relevant if you have opted into multi account support
- id: /subscriptions/1fbb2da1-2ce8-45e4-b85f-676ab8e12345/resourceGroups/payments-staging/providers/Microsoft.Compute/disks/payments-db-disk-staging
alias: payments-staging-disk # alias is optional and only relevant if you have opted into multi account support
# BambooHR
x-cortex-owners:
- type: group
name: Platform Engineering
provider: BAMBOO_HR
description: # optional
# Bitbucket
x-cortex-git:
bitbucket:
repository: cortexapps/payments-api
x-cortex-owners:
- type: group
name: platform-engineering
provider: BITBUCKET
description: # optional
# Bugsnag
x-cortex-bugsnag:
project: payments-api-prod
# Buildkite
x-cortex-ci-cd:
buildkite:
pipelines:
- slug: payments-api-build
- slug: payments-api-deploy
tags:
- tag: payments
- tag: backend
# Checkmarx
x-cortex-checkmarx:
projects:
- projectName: payments-api
- projectId: 8821
# CircleCI
x-cortex-circle-ci:
projects:
- projectSlug: gh/cortexapps/payments-api
alias: payments-api-circleci # alias is optional and only relevant if you have opted into multi account support
# ClickUp
x-cortex-issues:
clickup:
spaces:
- identifier: 987654321
identifierType: ID
folders:
- identifier: Platform Engineering
identifierType: NAME
tags:
- name: payments
- name: backend
# Codecov
x-cortex-static-analysis:
codecov:
owner: cortexapps
repo: payments-api
provider: AZURE_DEVOPS | BITBUCKET | BITBUCKET_SERVER | GITHUB | GITHUB_ENTERPRISE | GITLAB | GITLAB_ENTERPRISE
flag: unit
# Coralogix
x-cortex-coralogix:
applications:
- applicationName: payments-api
alias: payments-prod # alias is optional and only relevant if you have opted into multi account support
- applicationName: payments-worker
alias: payments-worker-prod # alias is optional and only relevant if you have opted into multi account support
# Datadog
x-cortex-apm:
datadog:
serviceTags: # List of tags & values
- tag: service
value: payments-api
- tag: env
value: prod
serviceName: payments-api
monitors:
- 12345678
- 12345679
x-cortex-slos:
datadog: # List of SLO ids
- id: abc123def456ghi7
- id: xyz789uvw012rst3
# Dynatrace
x-cortex-apm:
dynatrace:
entityIds:
- SERVICE-A1B2C3D4E5F60001
- SERVICE-A1B2C3D4E5F60002
entityNameMatchers:
- "payments.*"
x-cortex-slos:
dynatrace:
- id: slo-payments-availability
- id: slo-payments-latency
# Entra ID (Azure Active Directory)
x-cortex-owners:
- type: group
name: platform-engineering
provider: ACTIVE_DIRECTORY
description: # optional
# FireHydrant
x-cortex-firehydrant:
services:
- identifier: PYMT1234
identifierType: ID
- identifier: payments-api
identifierType: SLUG
# GitHub
x-cortex-git:
github:
repository: cortexapps/payments-api
basepath: payments-api # optional
x-cortex-owners:
- type: group
name: cortexapps/backend-platform # Must be of form <org>/<team>
provider: GITHUB
description: Backend platform team
# GitLab
x-cortex-git:
gitlab:
repository: cortexapps/platform/payments-api
basepath: payments-api # optional
x-cortex-owners:
- type: group
name: Platform Engineering
provider: GITLAB
description: Core platform team for payments infrastructure
# Google
x-cortex-owners:
- type: group
name: platform-engineering@cortex.io
provider: GOOGLE
x-cortex-dependency:
gcp:
labels:
- key: service
value: payments-api
- key: env
value: prod
x-cortex-infra:
Google Cloud:
resources:
- resourceName: us-central1/payments-processor-fn
projectId: cortex-platform-prod
resourceType: function
- resourceName: payments-assets-prod
projectId: cortex-platform-prod
resourceType: storage
x-cortex-slos:
gcp:
- projectId: cortex-platform-prod
serviceId: iLE2e4HvR_PaymentsAPI01
- projectId: cortex-platform-prod
serviceId: iLE2e4HvR_PaymentsWorker01
# Grafana
x-cortex-dashboards:
embeds:
- type: grafana
url: https://grafana.cortex.io/d/abcd1234/payments-api-overview
# incident.io
x-cortex-incident-io:
customFields:
- name: Service
value: Payments API
alias: payments-prod
- id: payments-worker-id
value: payments-worker
alias: payments-worker-prod
# Jira
x-cortex-issues:
jira:
labels:
- payments
- backend
components:
- api-gateway
projects:
- PLAT
- PAY
# Optional: Override Cortex default Jira query
defaultJql: 'project = PAY AND status = "In Progress" AND labels = "payments"'
# Kubernetes
x-cortex-k8s:
deployment:
- identifier: payments/payments-api
cluster: prod-us-west-2 # optional
- identifier: payments/payments-api
cluster: staging
- identifier: default/payments-api
cluster: prod-us-east-1
argorollout:
- identifier: payments/payments-api-canary
cluster: prod-us-west-2
statefulset:
- identifier: payments/payments-db-replica
cluster: prod-us-west-2
cronjob:
- identifier: payments/payments-reconciler
cluster: prod-us-west-2
# LaunchDarkly
x-cortex-launch-darkly:
projects:
- key: payments-platform
environments: # Optional
- environmentName: prod
- environmentName: staging
alias: payments-ld-prod # alias is optional and only relevant if you have opted into multi account support
- tag: backend-services
environments: # Optional
- environmentName: prod
alias: backend-ld-prod # alias is optional and only relevant if you have opted into multi account support
feature-flags:
- tag: payments-rollout
environments: # Optional
- environmentName: staging
alias: payments-flags-staging # alias is optional and only relevant if you have opted into multi account support
# Lightstep
x-cortex-slos:
lightstep:
- streamId: AbCdEfGhIjKlMnOp
targets:
latency:
- percentile: 0.99
target: 200
slo: 0.999
# Mend
x-cortex-static-analysis:
mend:
applicationIds:
- payments-api-mend
- payments-worker-mend
projectIds:
- cortexapps_payments-api
- cortexapps_payments-worker
# Microsoft Teams
x-cortex-microsoft-teams:
channels:
- name: payments-engineering
teamName: Platform Engineering
description: Channel for payments engineering discussions and alerts.
notificationsEnabled: true
# New Relic
x-cortex-apm:
newrelic:
applications:
- applicationId: 987654321
alias: payments-api-prod
tags:
- tag: service
value: payments-api
alias: payments-api-prod
x-cortex-dashboards:
embeds:
- type: newrelic
url: https://one.newrelic.com/dashboards/abc123def456-payments-api
# While the `applications` wrapper format is the recommended format, Cortex also supports a flat array format:
# x-cortex-apm:
# newrelic:
# - applicationId: 987654321
# Okta
x-cortex-owners:
- type: group
name: platform-engineering # group name in Okta
provider: OKTA
description: # optional
# OpsGenie
x-cortex-oncall:
opsgenie:
type: SCHEDULE
id: a1b2c3d4-e5f6-7890-abcd-ef1234567890 # Optionally, can use the Rotation UUID instead
x-cortex-owners:
- type: group
name: platform-engineering
provider: OPSGENIE
description: # optional
x-cortex-alerts:
- type: opsgenie
tag: service
value: payments-api
# PagerDuty
x-cortex-oncall:
pagerduty:
id: P1A2B3C # Service ID
type: SERVICE
x-cortex-oncall:
pagerduty:
id: S4D5E6F # Schedule ID
type: SCHEDULE
x-cortex-oncall:
pagerduty:
id: E7G8H9I # Escalation Policy ID
type: ESCALATION_POLICY
# Prometheus
x-cortex-slos:
prometheus:
- errorQuery: sum(rate(http_requests_total{service="payments-api",status=~"5.."}[5m]))
totalQuery: sum(rate(http_requests_total{service="payments-api"}[5m]))
slo: 0.999
alias: payments-prometheus
name: payments-api-availability
# Rollbar
x-cortex-rollbar:
project: payments-api
# Rootly
x-cortex-rootly:
services:
- id: PYMT5678
- slug: payments-api
# Sentry
x-cortex-sentry:
projects:
- name: payments-api
- name: payments-worker
# Semgrep
x-cortex-semgrep:
projects:
- alias: cortexapps
projectId: 1122334
- alias: cortexapps-oss
projectId: 4433221
# ServiceNow
x-cortex-servicenow:
services:
- tableName: cortex-platform-services
id: 42
x-cortex-owners:
- type: group
name: Platform Engineering
provider: SERVICE_NOW
description: Primary team responsible for payments infrastructure # optional
# Slack
x-cortex-slack:
channels:
- id: C04ABCDE123
notificationsEnabled: true
description: Payments team channel for engineering discussions
- name: payments-alerts
notificationsEnabled: true
description: Automated alerts channel for the Payments API
# Snyk
x-cortex-snyk:
projects:
- organizationId: a1b2c3d4-e5f6-7890-abcd-ef1234567890
projectId: f0e9d8c7-b6a5-4321-fedc-ba9876543210
source: CODE
# SonarQube
x-cortex-static-analysis:
sonarqube:
project: cortexapps_payments-api
alias: payments-sonar
# Splunk Observability Cloud (SignalFX)
x-cortex-slos:
signalfx:
- query: 'sf_metric:"request.latency" AND service:"payments-api"'
rollup: AVERAGE
target: 200
lookback: 3600000
operation: BELOW
# Splunk On-Call (VictorOps)
x-cortex-oncall:
victorops:
type: SCHEDULE
id: platform-engineering-24x7
# Sumo Logic
x-cortex-slos:
sumologic:
- id: 000000000001001
- id: 000000000001002
# Veracode
x-cortex-static-analysis:
veracode:
applicationNames:
- Payments API
- Payments Worker
sandboxes:
- applicationName: Payments API
sandboxName: payments-api-staging
- applicationName: Payments Worker
sandboxName: payments-worker-staging
# Wiz
x-cortex-wiz:
projects:
- projectId: 9a8b7c6d-e5f4-3210-abcd-ef1234567890
# Workday
x-cortex-owners:
- type: group
name: platform-engineering
provider: CORTEX
description: Platform Engineering team in Workday org structure
# xMatters
x-cortex-oncall:
xmatters:
id: platform-engineering-oncall
type: SERVICE