Examples
This page only references example files that currently exist in the uigraph-cli repository.
Repository example files
Full config example
examples/configs/.uigraph.yamlexamples/configs/.uigraph/openapi/storefront-sample.yamlexamples/configs/.uigraph/diagrams/login-flow/*examples/configs/.uigraph/diagrams/system-overview/*examples/configs/.uigraph/db/*
CI/CD examples
examples/ci-cd/github-actions.ymlexamples/ci-cd/github-actions-advanced.ymlexamples/ci-cd/gitlab-ci.yml
API specification examples
examples/specs/openapi/booking-service.yamlexamples/specs/openapi/payment-api.yamlexamples/specs/openapi/web-app-api.yamlexamples/specs/openapi/mobile-api.yamlexamples/specs/graphql/schema.graphqlexamples/specs/grpc/analytics.proto
1) Minimal service
version: 1
project:
name: mobile-platform
service:
name: Mobile API
category: Mobile
description: Backend API for mobile applications
repository:
provider: bitbucket
url: https://bitbucket.org/company/mobile-api
2) Service with APIs
version: 1
project:
name: analytics-platform
environment: production
service:
name: Analytics Service
category: Data
description: Real-time analytics processing and aggregation
repository:
provider: gitlab
url: https://gitlab.com/company/analytics-service
apis:
- name: analytics-graphql
type: graphql
path: ./specs/schema.graphql
- name: analytics-grpc
type: grpc
path: ./specs/analytics.proto
3) Service with Mermaid context
architectureDiagrams:
- name: Checkout Context Diagram
path: ./diagram-checkout.mmd
contextPath: ./context-checkout.json
4) Service with test packs
testPacks:
- name: checkout-regression
type: regression
testCases:
- type: api
title: apply-coupon returns 200
order: 1
apiGroupName: checkout-api
operationId: applyCoupon
expectedStatusCode: 200
requestTemplate: '{"code":"SAVE20"}'
isCritical: false
5) Service with multiple databases
databases:
- name: Core PostgreSQL Database
dbType: PostgreSQL
dialect: postgres
schemaPath: ./postgresql-core.sql
- name: Event MongoDB Database
dbType: MongoDB
dialect: mongodb
schemaPath: ./mongodb-events.json
6) Combined all-options example
version: 1
project:
name: one-service-all-options-project
environment: production
service:
name: One Service All Options
category: Backend
description: Single fixture combining APIs, diagrams, tests, and databases.
repository:
provider: github
url: https://github.com/example/one-service-all-options.git
apis:
- name: public-api
type: openapi
path: ./openapi-public.yaml
architectureDiagrams:
- name: Shape Context Diagram
path: ./diagram-shape.mmd
contextPath: ./context-shape.json
testPacks:
- name: smoke-pack
type: smoke
testCases:
- type: manual
title: smoke checkout path
order: 1
stepsList:
- action: Complete checkout with valid inputs
expectedResult: Checkout succeeds
expectedOutcome: Order is confirmed
requiresEvidence: true
isCritical: true
databases:
- name: Core MySQL Database
dbType: MySQL
dialect: mysql
schemaPath: ./mysql-core.sql
Tips
- Start from
examples/configs/.uigraph.yamlif you want one realistic end-to-end sample. - Add OpenAPI
operationIdvalues when your test cases need to target specific endpoints. - Keep example file paths repository-relative so dry-run and CI behave the same way.