openapi: 3.2.0 info: title: Harness Collections API version: '1.0' description: The Harness Software Delivery Platform uses OpenAPI Specification v3.0. contact: name: API Support email: contact@harness.io url: https://harness.io/ x-logo: url: https://mma.prnewswire.com/media/779232/Harnes_logo_horizontal.jpg?p=facebook altText: Harness termsOfService: https://harness.io/terms-of-use/ servers: - url: https://app.harness.io description: Harness host URL - url: https://{vanity} description: Vanity URL variables: vanity: default: app.harness.io security: - x-api-key: [] tags: - name: Collections description: This contains APIs specific to Collections paths: /v1/org/units/list: post: tags: - Collections summary: Retrieve a list of collections description: This API endpoint allows you to retrieve a list of collections. The endpoint is paginated. operationId: collections#listCollections requestBody: content: application/json: schema: type: object properties: page: type: integer description: The page number for pagination default: 0 page_size: type: integer description: The number of items per page (default may vary) filter: type: object properties: ou_category_id: type: array items: type: string description: Filter collections by category IDs x-codeSamples: - lang: cURL label: curl source: "curl -X POST 'https://app.harness.io/gratis/sei/api/v1/org/units/list' \\\n-H 'Content-Type: application/json' \\\n-H 'Authorization: APIKEY ' \\\n-d '{\n \"page\": 0,\n \"page_size\": 100,\n \"filter\": {\n \"ou_category_id\": [\"b5ba90ab-caf4-4fef-90bd-3816d2294547\"]\n }\n}'\n" responses: '200': description: OK response. content: application/json: schema: type: object properties: records: type: array items: type: object properties: id: type: string ou_id: type: string name: type: string tags: type: array items: type: string managers: type: array items: type: string admins: type: array items: type: string sections: type: array items: type: string version: type: string no_of_dashboards: type: integer path: type: string ou_category_id: type: string default_dashboard_id: type: integer workspace_id: type: integer created_at: type: integer parent_ref_id: type: - integer - 'null' workflow_profile_id: type: - string - 'null' workflow_profile_name: type: - string - 'null' count: type: integer _metadata: type: object properties: page_size: type: integer page: type: integer has_next: type: boolean total_count: type: integer example: records: - id: '76' ou_id: 8ffa98a4-c607-4d90-a333-b79bf095a7fb name: All Teams tags: [] managers: [] admins: [] sections: [] version: '1' no_of_dashboards: 3 path: /All Teams ou_category_id: ffaea171-ba57-4222-81b0-d26d3284c065 default_dashboard_id: 0 workspace_id: 34 created_at: 1710173818740 workflow_profile_id: f1d1d2f2-bba6-4f19-92c2-fcd4e4fa8116 workflow_profile_name: DORA profile - id: '79' ou_id: e1dc905b-0eca-4c4d-ad49-a3ce396fe0ff name: Frontend tags: [] managers: [] admins: [] sections: [] parent_ref_id: 76 version: '2' no_of_dashboards: 0 path: /All Teams/Frontend ou_category_id: ffaea171-ba57-4222-81b0-d26d3284c065 default_dashboard_id: 0 workspace_id: 34 created_at: 1710947467896 count: 2 _metadata: page_size: 100 page: 0 has_next: false total_count: 2 /v1/org/units: post: tags: - Collections summary: Create a new collection description: This API endpoint allows you to create a new collection. operationId: collections#createCollection requestBody: content: application/json: schema: type: array items: type: object properties: name: type: string description: The name of the new collection ou_category_id: type: string description: The ID of the category to which the collection belongs parent_ref_id: type: string description: The reference ID of the parent collection sections: type: array items: type: object properties: id: type: string description: A randomly generated UUID for the section integrations: type: object additionalProperties: type: object properties: type: type: string description: The type of integration (e.g., "jira", "github", "jenkins") filters: type: object description: Filters specific to the integration type x-codeSamples: - lang: cURL label: curl source: "curl -X POST 'https://app.harness.io/gratis/sei/api/v1/org/units' \\\n-H 'Content-Type: application/json' \\\n-H 'Authorization: APIKEY ' \\\n-d '[\n {\n \"name\": \"My Collection\",\n \"ou_category_id\": \"b5ba90ab-caf4-4fef-90bd-3816d2294547\",\n \"parent_ref_id\": \"33\",\n \"sections\": [\n {\n \"id\": \"96096840-e721-11ee-b664-7bab67f40a81\",\n \"integrations\": {\n \"1\": {\n \"type\": \"jira\",\n \"filters\": {\n \"projects\": [\"PROJECT1\", \"PROJECT2\", \"PROJECT3\"]\n }\n }\n }\n },\n {\n \"id\": \"9cb8ae30-e721-11ee-b664-7bab67f40a81\",\n \"integrations\": {\n \"2\": {\n \"type\": \"github\",\n \"filters\": {\n \"repo_ids\": [\"my-org/my-repo-1\", \"my-org/my-repo-2\", \"my-org/my-repo-3\"]\n }\n }\n }\n },\n {\n \"id\": \"9f1589f0-e721-11ee-b664-7bab67f40a81\",\n \"integrations\": {\n \"3\": {\n \"type\": \"jenkins\",\n \"filters\": {\n \"job_names\": [\"Pipeline1\", \"Pipeline2\", \"Pipeline3\"]\n }\n }\n }\n }\n ]\n }\n]'\n" responses: '200': description: OK response. content: application/json: schema: type: object properties: errors: type: array items: type: string success: type: array items: type: integer example: errors: [] success: - 82 put: tags: - Collections summary: Edit an existing collection description: This API endpoint allows you to edit an existing collection. operationId: collections#editCollection requestBody: content: application/json: schema: type: array items: type: object properties: id: type: string description: The reference ID of the collection to be edited name: type: - string - 'null' description: The new name for the collection ou_category_id: type: - string - 'null' description: The ID of the category to which the collection belongs parent_ref_id: type: - string - 'null' description: The reference ID of the parent collection sections: type: array items: type: object properties: id: type: string description: A randomly generated UUID for the section integrations: type: object additionalProperties: type: object properties: type: type: string description: The type of integration (e.g., "jira", "github", "jenkins") filters: type: object description: Filters specific to the integration type x-codeSamples: - lang: cURL label: curl source: "curl -X PUT 'https://app.harness.io/gratis/sei/api/v1/org/units' \\\n-H 'Content-Type: application/json' \\\n-H 'Authorization: APIKEY ' \\\n-d '[\n {\n \"id\": \"74\",\n \"name\": \"New Name\",\n \"ou_category_id\": \"b5ba90ab-caf4-4fef-90bd-3816d2294547\",\n \"parent_ref_id\": \"33\",\n \"sections\": [\n {\n \"id\": \"33024940-e728-11ee-b664-7bab67f40a81\",\n \"integrations\": {\n \"1\": {\n \"type\": \"jira\",\n \"filters\": {\n \"projects\": [\"PROJECT4\"]\n }\n }\n }\n }\n ]\n }\n]'\n" responses: '200': description: OK response. content: application/json: schema: type: object properties: errors: type: array items: type: string success: type: array items: type: integer example: errors: [] success: - 74 delete: tags: - Collections summary: Delete an existing collection description: This API endpoint allows you to delete an existing collection. operationId: collections#deleteCollection requestBody: content: application/json: schema: type: array items: type: string description: The reference ID of the collection to be deleted. Multiple IDs can be included in the array to delete multiple collections in a single request. x-codeSamples: - lang: cURL label: curl source: 'curl -X DELETE ''https://app.harness.io/gratis/sei/api/v1/org/units'' \ -H ''Content-type: application/json'' \ -H ''Authorization: APIKEY '' \ -d ''[""]'' ' responses: '200': description: OK response. content: application/json: schema: type: object properties: message: type: string example: The collection(s) were successfully deleted. example: message: The collection(s) were successfully deleted. components: securitySchemes: x-api-key: name: x-api-key type: apiKey in: header description: API key is a token provided while making the API calls. This is used to authenticate the client at the exposed endpoint. externalDocs: description: Find out more about Swagger url: http://swagger.io x-stoplight: id: oc91t4vrfnjyi x-tagGroups: - name: Organizations tags: - Organization - name: Projects tags: - Org Project - Project - name: Secrets tags: - Account Secret - Org Secret - Project Secret - Secrets - name: Connectors tags: - Account Connector - Org Connector - Project Connector - Connectors - GoogleSecretManagerConnector - name: Roles tags: - Account Roles - Organization Roles - Project Roles - Roles - name: Resource Groups tags: - Account Resource Groups - Organization Resource Groups - Project Resource Groups - Filter Resource Groups - Harness Resource Group - Zendesk - name: Role Assignments tags: - Account Role Assignments - Org Role Assignments - Project Role Assignments - Role Assignments - name: Platform tags: - Access Control List - Account Banner - Account Banner - Account Licensed Modules - Account License Type - Account Webhooks - AccountSetting - Accounts - Analyze Account Access Policy - Analyze Organization Access Policy - Analyze Project Access Policy - ApiKey - Audit - AuditFilters - Authentication Settings - Canny - Devops Essentials License Data By Account - EULA - Filter - Harness Resource Type - Invite - IP Allowlist - Nextgen Ldap - Notification Channels - Notification Rules - OIDC - Oidc-Access-Token - Oidc-ID-Token - Org Webhooks - Permissions - Project Webhooks - Secret Managers - Service Account - Setting - SMTP - Source Code Manager - Token - User - User Group - Variables - name: Delegate tags: - Agent mTLS Endpoint Management - Delegate Download Resource - Delegate Group Tags Resource - Delegate Setup Resource - Delegate Token Resource - name: Pipelines tags: - Pipelines - Input Sets - Approvals - Pipeline Execution - Pipeline Dashboard - Pipeline Input Set - Pipeline - Pipeline Execution Details - Pipeline Execute - Pipeline Refresh - Pipeline data retention - Triggers - TriggersEvents - Webhook Triggers - Webhook Event Handler - DryRunPipeline - name: Artifact Registry tags: - Registries - Artifacts - Docker Artifacts - Helm Artifacts - quarantine - Webhooks - Spaces - Replication - Registry V3 - Registries - Registry V3 - Packages - Registry V3 - Versions - Registry V3 - Files - Registry V3 - Metadata - Registry V3 - Firewall - Registry V3 - Transfer - name: Database DevOps tags: - Database Schema - Database Instance - Deployed State - Execution Config - Migration State - name: CD tags: - K8s Release Service Mapping - CustomDeployment - Environments - EnvironmentGroup - Infrastructures - Usage - File Store - Service Dashboard - ServiceOverrides - Rollback - tas - name: Deployment Freeze tags: - Freeze CRUD - Freeze Evaluation - Freeze Schema - name: Services tags: - Account Services - Org Services - Project Services - Services - name: Rancher Infrastructures tags: - Account Rancher Infrastructure - Org Rancher Infrastructure - Project Rancher Infrastructure - name: Templates tags: - Account Template - Org Template - Project Template - Templates - Global Templates - name: GitOps tags: - Agents - Application - Applications - Certificates - Clusters - Dashboard Aggregates - Dashboards - GnuPGP Keys - GPG Keys - Hosts - Project mappings - Projects - Reconciler - Repositories - Repository Certificates - Repository credentials - ValidateHost - name: GitX tags: - GitX Webhooks - Org Gitx Webhooks - Project Gitx Webhooks - name: CACM tags: - Anomalies Ignorelist Rule - Anomalies - BI Dashboards - Budgets - Budget Groups - Cost Categories - Cloud Accounts - K8S Connectors Metadata - Notification Settings v2 - Overview - Data Job Status - Recommendation cost settings - Unit Metric - Anomaly Comments - Cloud and AI cost anomaly details - Cloud and AI cost anomalies v2 - Cost Details - Currency Preferences - External Data Provider - AiEngine - CACM governance cost settings - Governance Enforcement Recommendation APIs - Governance Alert - Governance Overview - Governance Recommendation APIs - RuleEnforcement - Rule Executions - Rule - Rule Sets - Perspectives Folders - Perspective Reports - Perspectives - Cost Category Jira Project Mapping - Recommendations Details - Recommendations - Recommendation Jira - Recommendation Preferences - Recommendation Presets - Recommendation Servicenow - Recommendation Tags - Recommendation Ignore List - AutoStopping Rules - AutoStopping Rules V2 - AutoStopping Load Balancers - AutoStopping Fixed Schedules - AutoStopping Alerts - Commitment Orchestrator Events APIs - name: Feature Flags tags: - API Keys - Feature Flags - Targets - Target Groups - Environment Perspectives - Anomalies - Proxy - Tags - name: SRM tags: - Monitored Services - SLOs dashboard - NG SLOs - SLOs - Downtime - Srm Notification - name: Internal Developer Portal - IDP tags: - Entities - Teams - CatalogCustomProperties - Scores - DataSource - KubernetesDataPoints - AggregationRules - AppConfig - PluginInfo - LayoutProxy - Kinds - LayoutsV3 - LayoutsV4 - name: Environment Management - IDP tags: - Environment - Infrastructure - Instance - name: Custom Dashboards tags: - aida - dashboards - downloads - embed - folders - name: Policy Management tags: - dashboard - examples - policies - evaluate - evaluations - policysets - system - name: Code tags: - repository - status_checks - pullreq - upload - webhook - resource - rules - labels - name: IaCM tags: - usage - approvals - costs - executions - module-registry - workspaces - settings - tf-standard-backend - variables - name: STO tags: - Exemptions - Issues - Scans - Products - Test Targets - Target Variants - name: SEI tags: - Collection categories - Collections - Contributors - DORA - name: Git Sync (deprecated) tags: - Git Branches - Git Full Sync - Git Sync Settings - Git Sync - Git Sync Errors - name: Error Models tags: - Error Response - Governance Metadata - name: Supply Chain Security tags: - integration - PipelineInfraConfig - SBOM - Integration Step Config - Delete Step Config - Delete Repositories - Pipeline Store Config - Evidence Vault [Beta] - name: Release Management tags: - Release Groups - Releases - Orchestration Processes - Orchestration Activities - Orchestration Executions - Conflicts - Freeze - Reports - Uploads - name: Resilience Testing tags: - Actions - Action Templates - Chaos Components - Chaos Hubs - ChaosGuard Conditions - ChaosGuard Rules - DR Tests - Experiments - Experiment Templates - Faults - Fault Templates - Chaos Infrastructure - Health - Network Maps - Onboarding - Probes - Probe Templates - Chaos Recommendations - Risks