API Reference
Complete API documentation for integrating with opsinit. Build powerful applications and automate your deployment workflows.
RESTful API
Simple and powerful integration
Our RESTful API provides programmatic access to all opsinit features. Use standard HTTP methods and JSON for all requests and responses.
- RESTful Design
Standard HTTP methods (GET, POST, PUT, DELETE) with consistent JSON request/response formats.
- Authentication
Bearer token authentication with secure API keys for programmatic access.
- Rate Limiting
Generous rate limits with proper headers for monitoring your API usage.
API Endpoints
Complete endpoint reference
All available API endpoints organized by category with detailed descriptions and usage examples.
Projects
/api/projects
List all projects for the authenticated user
/api/projects
Create a new project
/api/projects/{id}
Get project details by ID
/api/projects/{id}
Update project configuration
/api/projects/{id}
Delete a project
Analysis
/api/analysis
Start code analysis for a repository
/api/analysis/{id}
Get analysis results by ID
/api/analysis/{id}/status
Check analysis status
Deployments
/api/deployments
Create a new deployment
/api/deployments
List all deployments
/api/deployments/{id}
Get deployment details
/api/deployments/{id}/rollback
Rollback deployment to previous version
GitHub Integration
/api/github/repositories
List connected GitHub repositories
/api/github/connect
Connect a GitHub repository
/api/github/disconnect/{id}
Disconnect a GitHub repository
Code Examples
Get started quickly
Practical examples in multiple programming languages to help you integrate with our API.
Create a new project
const response = await fetch('/api/projects', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'Authorization': 'Bearer YOUR_API_TOKEN'
},
body: JSON.stringify({
name: 'My Project',
description: 'A new project',
repositoryUrl: 'https://github.com/user/repo'
})
});
const project = await response.json();
Start code analysis
import requests
response = requests.post(
'https://api.opsinit.com/api/analysis',
headers={
'Authorization': 'Bearer YOUR_API_TOKEN',
'Content-Type': 'application/json'
},
json={
'projectId': 'project-id',
'repositoryUrl': 'https://github.com/user/repo'
}
)
analysis = response.json()
Get deployment status
curl -X GET \
https://api.opsinit.com/api/deployments/deployment-id \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json"
Ready to integrate?
Start building with our API today. Get your API key and begin integrating opsinit into your applications.