# JSMON API

## GET /api/v2/workspaces

> Endpoint for getting all workspaces for the authenticated user with summary statistics

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/workspaces":{"get":{"description":"Endpoint for getting all workspaces for the authenticated user with summary statistics","responses":{"200":{"description":"Workspaces fetched successfully","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"wkspId":{"type":"string","description":"Workspace ID"},"name":{"type":"string","description":"Name of the workspace"},"userId":{"type":"string","description":"User ID who owns the workspace"},"createdAt":{"type":"string","format":"date-time","description":"Workspace creation timestamp"},"lastOpenedAt":{"type":"string","format":"date-time","description":"Last time workspace was opened"},"summary":{"type":"object","properties":{"jsUrls":{"type":"integer","description":"Count of JavaScript URLs scanned in this workspace"},"domains":{"type":"integer","description":"Count of domains scanned in this workspace"},"keysAndSecrets":{"type":"integer","description":"Count of keys and secrets found in this workspace"},"jsIntelligenceResults":{"type":"integer","description":"Count of JavaScript intelligence results in this workspace"}}}}}}}}},"401":{"description":"Unauthorized"},"403":{"description":"Forbidden"},"500":{"description":"Internal server error"}}}}}}
```

## DELETE /api/v2/deleteByFileId

> Endpoint for deleting all data associated with an array of FileId

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/deleteByFileId":{"delete":{"description":"Endpoint for deleting all data associated with an array of FileId","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id"}],"requestBody":{"content":{"application/json":{"schema":{"type":"array","items":{"type":"string","format":"uuid"},"description":"Comma-separated list of file IDs to be deleted"}}},"required":true},"responses":{"200":{"description":"Successfully deleted!!"}}}}}}
```

## DELETE /api/v2/deleteByDomain

> Endpoint for deleting all data associated with a domain in a workspace

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/deleteByDomain":{"delete":{"description":"Endpoint for deleting all data associated with a domain in a workspace","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id"},{"in":"query","name":"fileId","required":true,"schema":{"type":"string","properties":{"fileId":{"type":"string","format":"uuid"}}},"description":"The ID of the file which got created after JS Url Extraction"}],"responses":{"200":{"description":"Successfully deleted!!"}}}}}}
```

## POST /api/v2/queryBuilder

> Endpoint for building queries based on fields and domains with pagination support.

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/queryBuilder":{"post":{"description":"Endpoint for building queries based on fields and domains with pagination support.","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace ID"}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"query":{"type":"string","description":"The query string to be processed"}}}}},"description":"Query parameters to fetch specific results based on field, domain, and page","required":true},"responses":{"200":{"description":"Successfully retrieved query results","content":{"application/json":{"schema":{"type":"object","properties":{"urls":{"type":"array","items":{"type":"string"}},"paginatedResults":{"type":"array","items":{"type":"object"}}}}}}},"400":{"description":"Bad Request - Query or field parameters are missing or invalid"},"401":{"description":"Unauthorized - User not authenticated"},"403":{"description":"Forbidden - User does not have access to the workspace"},"500":{"description":"Internal Server Error - An error occurred while processing the query"}}}}}}
```

## GET /api/v2/recentQueries

> Fetch recent queries made by the user within a specific workspace.

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/recentQueries":{"get":{"description":"Fetch recent queries made by the user within a specific workspace.","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace ID to fetch the recent queries from."}],"responses":{"200":{"description":"Successfully retrieved recent queries.","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object"}}}}}}},"401":{"description":"Unauthorized - User is not authenticated."},"403":{"description":"Forbidden - User does not have access to the workspace or it doesn't exist."},"500":{"description":"Internal Server Error - An error occurred while processing the request."}}}}}}
```

## DELETE /api/v2/deleteBywkspId

> Endpoint for deleting all data associated with a workspace

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/deleteBywkspId":{"delete":{"description":"Endpoint for deleting all data associated with a workspace","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id"}],"responses":{"200":{"description":"Successfully deleted!!"}}}}}}
```

## PUT /api/v2/updateWkspLastOpenedAt

> Endpoint for updating last opened at time of workspace

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/updateWkspLastOpenedAt":{"put":{"description":"Endpoint for updating last opened at time of workspace","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id"}],"responses":{"204":{"description":""}}}}}}
```

## POST /api/v2/createWorkspace

> Endpoint for creating a workspace

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/createWorkspace":{"post":{"description":"Endpoint for creating a workspace","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string"}}}}},"description":"The name of the workspace","required":true},"responses":{"201":{"description":"Workspace created successfully"}}}}}}
```

## PUT /api/v2/updateWorkspace

> Endpoint for updating a workspace

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/updateWorkspace":{"put":{"description":"Endpoint for updating a workspace","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id"}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string"}}}}},"description":"The new name of the workspace","required":true},"responses":{"204":{"description":""}}}}}}
```

## GET /api/v2/getCustomWords

> Fetch custom words associated with the user and workspace.

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/getCustomWords":{"get":{"description":"Fetch custom words associated with the user and workspace.","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace ID to fetch custom words for."}],"responses":{"200":{"description":"Successfully retrieved custom words.","content":{"application/json":{"schema":{"type":"object","properties":{"workspaceId":{"type":"string","format":"uuid","description":"The workspace ID."},"customWords":{"type":"array","items":{"type":"string"}}}}}}},"400":{"description":"Bad Request - Invalid input (missing userId or workspaceId)."},"403":{"description":"Forbidden - User does not have access to the workspace or it doesn't exist."},"404":{"description":"Not Found - User not found."},"500":{"description":"Internal Server Error - An error occurred while processing the request."}}}}}}
```

## POST /api/v2/uploadUrl

> Endpoint for uploading single URL

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/uploadUrl":{"post":{"description":"Endpoint for uploading single URL","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"url":{"type":"string"}}}}},"description":"URL to upload"},"responses":{"200":{"description":"URL successfully uploaded"}}}}}}
```

## GET /api/v2/fetchScans

> Endpoint for fetching scans with filtering, pagination and sorting capabilities

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/fetchScans":{"get":{"description":"Endpoint for fetching scans with filtering, pagination and sorting capabilities","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to fetch scans from"},{"in":"query","name":"category","required":false,"schema":{"type":"string","items":{"type":"string","enum":["urlScan","fileScan","domainScan"]}},"description":"Filter by scan categories"},{"in":"query","name":"status","required":false,"schema":{"type":"string","items":{"type":"string","enum":["success","failed","inProgress"]}},"description":"Filter by scan status"},{"in":"query","name":"scoreMin","required":false,"schema":{"type":"string","minimum":0,"maximum":10},"description":"Minimum threat score filter"},{"in":"query","name":"scoreMax","required":false,"schema":{"type":"string","minimum":0,"maximum":10},"description":"Maximum threat score filter"},{"in":"query","name":"dateFrom","required":false,"schema":{"type":"string","format":"date"},"description":"Filter scans from this date"},{"in":"query","name":"dateTo","required":false,"schema":{"type":"string","format":"date"},"description":"Filter scans up to this date"},{"in":"query","name":"page","required":false,"schema":{"type":"string","default":1},"description":"Page number for pagination"},{"in":"query","name":"limit","required":false,"schema":{"type":"string","default":20},"description":"Number of items per page"},{"in":"query","name":"sortBy","required":false,"schema":{"type":"string","default":"lastScannedOn"},"description":"Field to sort by"},{"in":"query","name":"sortOrder","required":false,"schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"Sort order"},{"in":"query","name":"search","required":false,"schema":{"type":"string"},"description":"Search term for filtering scans"}],"responses":{"200":{"description":"Scans fetched successfully","content":{"application/json":{"schema":{"type":"object","properties":{"scans":{"type":"array","items":{"type":"object"}},"totalCount":{"type":"integer"},"currentPage":{"type":"integer"},"totalPages":{"type":"integer"}}}}}},"400":{"description":"Invalid parameters"},"401":{"description":"Unauthorized"},"403":{"description":"Forbidden"}}}}}}
```

## GET /api/v2/scanSummary

> Endpoint for getting scan summary overview

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/scanSummary":{"get":{"description":"Endpoint for getting scan summary overview","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id"},{"in":"query","name":"runId","required":true,"schema":{"type":"string"},"description":"The run id of the scan"}],"responses":{"200":{"description":"Scan summary fetched successfully","content":{"application/json":{"schema":{"type":"object","properties":{"runId":{"type":"string"},"category":{"type":"string","enum":["urlScan","fileScan","domainScan"]},"asset":{"type":"string"},"status":{"type":"string","enum":["success","failed","inProgress"]},"summary":{"type":"object"}}}}}},"400":{"description":"Missing required parameters or invalid category"},"401":{"description":"Unauthorized"},"403":{"description":"Forbidden"},"404":{"description":"Scan not found"}}}}}}
```

## GET /api/v2/scanSummaryKeysandSecrets

> Endpoint for getting scan summary keys and secrets information

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/scanSummaryKeysandSecrets":{"get":{"description":"Endpoint for getting scan summary keys and secrets information","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id"},{"in":"query","name":"runId","required":true,"schema":{"type":"string"},"description":"The run id of the scan"}],"responses":{"200":{"description":"Scan keys and secrets summary fetched successfully","content":{"application/json":{"schema":{"type":"object","properties":{"runId":{"type":"string"},"category":{"type":"string","enum":["urlScan","fileScan","domainScan"]},"asset":{"type":"string"},"status":{"type":"string","enum":["success","failed","inProgress"]},"keysAndSecrets":{"type":"object"}}}}}},"400":{"description":"Missing required parameters or invalid category"},"401":{"description":"Unauthorized"},"403":{"description":"Forbidden"},"404":{"description":"Scan not found"}}}}}}
```

## GET /api/v2/scanSummaryJsIntelligence

> Endpoint for getting scan summary JavaScript intelligence information

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/scanSummaryJsIntelligence":{"get":{"description":"Endpoint for getting scan summary JavaScript intelligence information","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id"},{"in":"query","name":"runId","required":true,"schema":{"type":"string"},"description":"The run id of the scan"}],"responses":{"200":{"description":"Scan JavaScript intelligence summary fetched successfully","content":{"application/json":{"schema":{"type":"object","properties":{"runId":{"type":"string"},"category":{"type":"string","enum":["urlScan","fileScan","domainScan"]},"asset":{"type":"string"},"status":{"type":"string","enum":["success","failed","inProgress"]},"jsIntelligence":{"type":"object"}}}}}},"400":{"description":"Missing required parameters or invalid category"},"401":{"description":"Unauthorized"},"403":{"description":"Forbidden"},"404":{"description":"Scan not found"}}}}}}
```

## POST /api/v2/compareJsmonIds

> Compare two jsmon ids

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/compareJsmonIds":{"post":{"description":"Compare two jsmon ids","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"},{"in":"query","name":"jsmonId1","required":true,"schema":{"type":"string"},"description":"The first jsmon id to compare"},{"in":"query","name":"jsmonId2","required":true,"schema":{"type":"string","description":"The second jsmon id to compare"}}],"responses":{"200":{"description":"successfully compared the jsmonIds"}}}}}}
```

## POST /api/v2/generateReport/

> Endpoint for creating a report for the given domainNames

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/generateReport/":{"post":{"description":"Endpoint for creating a report for the given domainNames","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["domainName","name"],"properties":{"domainName":{"type":"array","description":"Array of domain names for the report (cannot be empty)","items":{"type":"string"}},"name":{"type":"string","description":"Name of the report"}}}},"Authorization":{"schema":{"type":"object","required":["domainName","name"],"properties":{"domainName":{"type":"array","description":"Array of domain names for the report (cannot be empty)","items":{"type":"string"}},"name":{"type":"string","description":"Name of the report"}}}}},"description":"Payload containing domain names and a report name","required":true},"responses":{"200":{"description":"Report generated successfully"}}}}}}
```

## GET /api/v2/searchAllUrls/

> Endpoint for fetching all urls of a user/org

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[],"description":"for creating a report for the given domainNames"}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/searchAllUrls/":{"get":{"description":"Endpoint for fetching all urls of a user/org","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"}],"responses":{"200":{"description":"urls fetched successfully"}}}}}}
```

## GET /api/v2/dashboard/

> Endpoint for fetching dashboard data of a user/org

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/dashboard/":{"get":{"description":"Endpoint for fetching dashboard data of a user/org","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"}],"responses":{"200":{"description":"dashboard data fetched successfully"}}}}}}
```

## GET /api/v2/getWorkspaceSummary

> Endpoint for getting workspace summary with statistics and severe issues

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/getWorkspaceSummary":{"get":{"description":"Endpoint for getting workspace summary with statistics and severe issues","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to get summary for"}],"responses":{"200":{"description":"Workspace summary fetched successfully","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"workspaceName":{"type":"string","description":"Name of the workspace"},"wkspId":{"type":"string","description":"Workspace ID"},"createdAt":{"type":"string","format":"date-time","description":"Workspace creation timestamp"},"lastOpenedAt":{"type":"string","format":"date-time","description":"Last time workspace was opened"},"summary":{"type":"object","properties":{"jsUrls":{"type":"integer","description":"Count of JavaScript URLs scanned"},"keysAndSecrets":{"type":"integer","description":"Count of keys and secrets found"},"jsIntelligenceResults":{"type":"integer","description":"Count of JavaScript intelligence results"}}},"severeIssues":{"type":"array","description":"List of severe issues (limited to 25)","items":{"type":"object"}}}}}}}}}},"400":{"description":"wkspId query parameter is required"},"401":{"description":"Unauthorized"},"403":{"description":"Forbidden"},"404":{"description":"Workspace not found"},"500":{"description":"Internal server error"}}}}}}
```

## GET /api/v2/severityIssues/

> Endpoint for fetching severity issues of a user/org

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/severityIssues/":{"get":{"description":"Endpoint for fetching severity issues of a user/org","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"}],"responses":{"200":{"description":"severity issues fetched successfully"}}}}}}
```

## DELETE /api/v2/deleteUrl/{ID}

> Endpoint for deleting a url associated with a user/org with jsmonId

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/deleteUrl/{ID}":{"delete":{"description":"Endpoint for deleting a url associated with a user/org with jsmonId","parameters":[{"in":"path","name":"ID","description":"for deleting single jsmon","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"url deleted"}}}}}}
```

## POST /api/v2/viewReport/

> Endpoint viewing a report

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/viewReport/":{"post":{"description":"Endpoint viewing a report","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"fileId":{"type":"string"}}}},"Authorization":{"schema":{"type":"object","properties":{"fileId":{"type":"string"}}}}},"description":"for viewing a report based on the fileID"},"responses":{"200":{"description":"Report found"}}}}}}
```

## DELETE /api/v2/deleteReport/

> Endpoint for deleting the report

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/deleteReport/":{"delete":{"description":"Endpoint for deleting the report","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"fileId":{"type":"string"}}}},"Authorization":{"schema":{"type":"object","properties":{"fileId":{"type":"string"}}}}},"description":"for deleting single report"},"responses":{"200":{"description":"file deleted"}}}}}}
```

## POST /api/v2/uploadFile

> Upload file containing URLs (one URL per line)

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/uploadFile":{"post":{"description":"Upload file containing URLs (one URL per line)","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"}],"requestBody":{"content":{"multipart/form-data":{"schema":{"type":"object","properties":{"file":{"description":"File with URLs","type":"string","format":"binary"}}}}}},"responses":{"200":{"description":"File ID"}}}}}}
```

## GET /api/v2/scanFIle/{id}

> Scan specific file

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/scanFIle/{id}":{"get":{"description":"Scan specific file","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"},{"in":"path","name":"id","description":"File ID","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"Success"}}}}}}
```

## GET /api/v2/viewFile/{ID}

> Returns content of specific File

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/viewFile/{ID}":{"get":{"description":"Returns content of specific File","parameters":[{"in":"path","name":"ID","description":"File ID","schema":{"type":"string"},"required":true},{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"}],"responses":{"200":{"description":"File content"}}}}}}
```

## POST /api/v2/unminify

> Returns unminified version of code fetched from provided URL

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/unminify":{"post":{"description":"Returns unminified version of code fetched from provided URL","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"url":{"type":"string"}}}}},"description":"URL to fetch js and unminify"},"responses":{"200":{"description":"Unminified code"}}}}}}
```

## POST /api/v2/unminifycode

> Returns unminified version of provided code (plaintext)

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/unminifycode":{"post":{"description":"Returns unminified version of provided code (plaintext)","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string"}}}}},"description":"Code to unminify"},"responses":{"200":{"description":"Unminified code"}}}}}}
```

## POST /api/v2/compare

> Compare two different URLs

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/compare":{"post":{"description":"Compare two different URLs","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"id1":{"type":"string"},"id2":{"type":"string"}}}}},"description":"id1 and id2 of URLs to compare"},"responses":{"200":{"description":"Comparison result"}}}}}}
```

## DELETE /api/v2/deleteFIle/{ID}

> Delete specific file

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/deleteFIle/{ID}":{"delete":{"description":"Delete specific file","parameters":[{"in":"path","name":"ID","description":"File ID","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"Success"}}}}}}
```

## GET /api/v2/rescanURL/{ID}

> Rescans specific URL

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/rescanURL/{ID}":{"get":{"description":"Rescans specific URL","parameters":[{"in":"path","name":"ID","description":"URL ID","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"Success"}}}}}}
```

## POST /api/v2/bulkDeleteFiles

> For bulk deleting files

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/bulkDeleteFiles":{"post":{"description":"For bulk deleting files","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"}],"requestBody":{"content":{"application/json":{"schema":{"type":"array","items":{"type":"string"}}}},"description":"Files to delete"},"responses":{"200":{"description":"Success"}}}}}}
```

## POST /api/v2/moduleScannerForFile

> Endpoint to scan file

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/moduleScannerForFile":{"post":{"description":"Endpoint to scan file","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"moduleIds":{"type":"array","items":{"type":"string"}},"fileId":{"type":"string"}}}}},"description":"moduleIds and fileId"},"responses":{"200":{"description":"Sucess"}}}}}}
```

## POST /api/v2/moduleScannerForUrl

> Endpoint to scan URL

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/moduleScannerForUrl":{"post":{"description":"Endpoint to scan URL","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"moduleIds":{"type":"array","items":{"type":"string"}},"jsmonId":{"type":"string"}}}}},"description":"moduleIds and jsmonId"},"responses":{"200":{"description":"Sucess"}}}}}}
```

## POST /api/v2/automateScanDomain

> Endpoint to automate scan domain

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/automateScanDomain":{"post":{"description":"Endpoint to automate scan domain","parameters":[{"in":"wkspId","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"domain":{"type":"string","description":"The domain to be scanned"},"words":{"type":"array","description":"Array of words for scanning","items":{"type":"string"}},"headers":{"type":"array","description":"Array of header strings for scanning","items":{"type":"string"}}}}}},"description":"Request payload containing domain, words, and headers","required":["domain"]},"responses":{"200":{"description":"Sucess"}}}}}}
```

## POST /api/v2/automateScanFile

> Endpoint to automate scan data collection for given domain names via file upload

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/automateScanFile":{"post":{"description":"Endpoint to automate scan data collection for given domain names via file upload","requestBody":{"content":{"multipart/form-data":{"schema":{"type":"object","properties":{"file":{"description":"The file containing domain names","type":"string","format":"binary"}},"required":["file"]}}},"required":true},"responses":{"200":{"description":"Success"},"400":{"description":"Bad Request - Invalid or missing file"},"500":{"description":"Internal Server Error"}}}}}}
```

## POST /api/v2/searchUrlbyDomain/

> Endpoint to search URLs by domain

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}},"requestBodies":{"Obj3":{"content":{"application/json":{"schema":{"type":"object","properties":{"domain":{"type":"string"},"showOnly":{"type":"string"}}}}}}}},"paths":{"/api/v2/searchUrlbyDomain/":{"post":{"description":"Endpoint to search URLs by domain","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"}],"requestBody":{"$ref":"#/components/requestBodies/Obj3"},"responses":{"200":{"description":"Sucess"}}}}}}
```

## POST /api/v2/searchAutomation

> Endpoint to search automation

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}},"requestBodies":{"Obj3":{"content":{"application/json":{"schema":{"type":"object","properties":{"domain":{"type":"string"},"showOnly":{"type":"string"}}}}}}}},"paths":{"/api/v2/searchAutomation":{"post":{"description":"Endpoint to search automation","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"}],"requestBody":{"$ref":"#/components/requestBodies/Obj3"},"responses":{"200":{"description":"Sucess"}}}}}}
```

## PUT /api/v2/startCron

> Endpoint for starting cron job

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}},"requestBodies":{"Obj2":{"content":{"application/json":{"schema":{"type":"object","properties":{"url":{"type":"string"},"notificationChannel":{"type":"string","enum":["Slack","Email","Discord"],"description":"Notification channel options"},"vulnerabilitiesType":{"type":"string","enum":["URLs","Analysis","Scanner"],"description":"Types of vulnerabilities"},"time":{"type":"integer","minimum":0,"maximum":24,"description":"Time in hours (0 to 24)"},"domains":{"type":"array","items":{"type":"string"},"description":"Array of domains"}}}}},"description":"Payload including URL and additional parameters"}}},"paths":{"/api/v2/startCron":{"put":{"description":"Endpoint for starting cron job","requestBody":{"$ref":"#/components/requestBodies/Obj2"},"responses":{"200":{"description":"CronJob scheduled successfully"},"400":{"description":"Bad request, check input data"}}}}}}
```

## GET /api/v2/getCronJob

> Endpoint for getting cron job data

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/getCronJob":{"get":{"description":"Endpoint for getting cron job data","parameters":[{"in":"NA","schema":{"type":"string"}}],"responses":{"200":{"description":"Send the cronData for the userId or the orgId"}}}}}}
```

## PUT /api/v2/stopCron

> Endpoint for stopping cron job

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/stopCron":{"put":{"description":"Endpoint for stopping cron job","responses":{"200":{"description":"CronJob stopped successfully"}}}}}}
```

## PUT /api/v2/updateCron

> Endpoint for starting cron job

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}},"requestBodies":{"Obj2":{"content":{"application/json":{"schema":{"type":"object","properties":{"url":{"type":"string"},"notificationChannel":{"type":"string","enum":["Slack","Email","Discord"],"description":"Notification channel options"},"vulnerabilitiesType":{"type":"string","enum":["URLs","Analysis","Scanner"],"description":"Types of vulnerabilities"},"time":{"type":"integer","minimum":0,"maximum":24,"description":"Time in hours (0 to 24)"},"domains":{"type":"array","items":{"type":"string"},"description":"Array of domains"}}}}},"description":"Payload including URL and additional parameters"}}},"paths":{"/api/v2/updateCron":{"put":{"description":"Endpoint for starting cron job","requestBody":{"$ref":"#/components/requestBodies/Obj2"},"responses":{"200":{"description":"CronJob scheduled successfully"},"400":{"description":"Bad request, check input data"}}}}}}
```

## GET /getRecentScans

> Endpoint to fetch recent scans

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/getRecentScans":{"get":{"description":"Endpoint to fetch recent scans","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"},{"in":"query","name":"word","required":false,"schema":{"type":"string"},"description":"The word to search"}],"responses":{"200":{"description":"Success"}}}}}}
```

## GET /getWorkspaces

> Endpoint to fetch all the workspaces

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/getWorkspaces":{"get":{"description":"Endpoint to fetch all the workspaces","responses":{"200":{"description":"Workspaces Retrieved Successfully"}}}}}}
```

## POST /uploadLogoWorkspace

> Endpoint to upload logo for workspace

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/uploadLogoWorkspace":{"post":{"description":"Endpoint to upload logo for workspace","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the logo"}],"requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"type":"object","properties":{"file":{"description":"The logo to upload","type":"string","format":"binary"}},"required":["file"]}}},"required":true},"responses":{"200":{"description":"Logo uploaded successfully"}}}}}}
```

## GET /api/v2/viewFiles

> Endpoint to view files

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/viewFiles":{"get":{"description":"Endpoint to view files","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to view the files"},{"in":"query","name":"search","required":false,"schema":{"type":"string"},"description":"The search query to filter the files"}],"responses":{"200":{"description":"Files viewed successfully"}}}}}}
```

## POST /api/v2/addCustomWords

> Endpoint to add custom words

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/addCustomWords":{"post":{"description":"Endpoint to add custom words","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to add the custom words"}],"requestBody":{"content":{"application/json":{"schema":{"type":"array","items":{"type":"string"}}}},"description":"The custom words to add","required":true},"responses":{"default":{"description":"Default response"}}}}}}
```

## GET /api/v2/reports

> Endpoint to fetch all the reports

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/reports":{"get":{"description":"Endpoint to fetch all the reports","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"}],"responses":{"200":{"description":"Sucess"}}}}}}
```

## GET /api/v2/getDomains

> Endpoint to fetch all the domains

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/getDomains":{"get":{"description":"Endpoint to fetch all the domains","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"}],"responses":{"200":{"description":"Sucess"}}}}}}
```

## POST /api/v2/getEmails

> Endpoint to fetch all the emails

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}},"requestBodies":{"Obj4":{"content":{"application/json":{"schema":{"type":"object","required":["domains"],"properties":{"domains":{"type":"array","items":{}}}}}}}}},"paths":{"/api/v2/getEmails":{"post":{"description":"Endpoint to fetch all the emails","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"}],"requestBody":{"$ref":"#/components/requestBodies/Obj4"},"responses":{}}}}}
```

## POST /api/v2/getIps

> Endpoint to fetch all the ips

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}},"requestBodies":{"Obj4":{"content":{"application/json":{"schema":{"type":"object","required":["domains"],"properties":{"domains":{"type":"array","items":{}}}}}}}}},"paths":{"/api/v2/getIps":{"post":{"description":"Endpoint to fetch all the ips","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"}],"requestBody":{"$ref":"#/components/requestBodies/Obj4"},"responses":{"200":{"description":"Sucess"}}}}}}
```

## POST /api/v2/getS3Domains

> Endpoint to fetch all the s3 domains

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}},"requestBodies":{"Body":{"content":{"application/json":{"schema":{"type":"object","required":["domains"],"properties":{"domains":{"type":"array","items":{"type":"string"}}}}}}}}},"paths":{"/api/v2/getS3Domains":{"post":{"description":"Endpoint to fetch all the s3 domains","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"}],"requestBody":{"$ref":"#/components/requestBodies/Body"},"responses":{"200":{"description":"Sucess"}}}}}}
```

## POST /api/v2/getGqlOps

> Endpoint to fetch all the GQL Query

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}},"requestBodies":{"Body":{"content":{"application/json":{"schema":{"type":"object","required":["domains"],"properties":{"domains":{"type":"array","items":{"type":"string"}}}}}}}}},"paths":{"/api/v2/getGqlOps":{"post":{"description":"Endpoint to fetch all the GQL Query","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"}],"requestBody":{"$ref":"#/components/requestBodies/Body"},"responses":{"200":{"description":"Sucess"}}}}}}
```

## POST /api/v2/getDomainsUrls

> Endpoint to fetch all the domains urls

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}},"requestBodies":{"Body":{"content":{"application/json":{"schema":{"type":"object","required":["domains"],"properties":{"domains":{"type":"array","items":{"type":"string"}}}}}}}}},"paths":{"/api/v2/getDomainsUrls":{"post":{"description":"Endpoint to fetch all the domains urls","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"}],"requestBody":{"$ref":"#/components/requestBodies/Body"},"responses":{"200":{"description":"Sucess"}}}}}}
```

## GET /api/v2/getData

> Endpoint to fetch all the data count

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/getData":{"get":{"description":"Endpoint to fetch all the data count","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"}],"responses":{"200":{"description":"Sucess"}}}}}}
```

## POST /api/v2/getJsmonId

> Endpoint to fetch all the jsmon ids of a URL

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/getJsmonId":{"post":{"description":"Endpoint to fetch all the jsmon ids of a URL","parameters":[{"in":"query","name":"wkspId","required":true,"schema":{"type":"string","format":"uuid"},"description":"The workspace id to upload the URL"}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["url"],"properties":{"url":{"type":"string"}}}}}},"responses":{"200":{"description":"Sucess"}}}}}}
```

## POST /api/v2/sendOtp

> Endpoint to send Otp for Verification

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"paths":{"/api/v2/sendOtp":{"post":{"description":"Endpoint to send Otp for Verification","requestBody":{"$ref":"#/components/requestBodies/Obj"},"responses":{"200":{"description":"Verification OTP sent successfully, please check your spam as well."}}}}},"components":{"requestBodies":{"Obj":{"content":{"application/json":{"schema":{"type":"object","properties":{"email":{"type":"string"}}}}}}}}}
```

## POST /api/v2/isUserExist

> Endpoint to check whether the user exist already or not

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"paths":{"/api/v2/isUserExist":{"post":{"description":"Endpoint to check whether the user exist already or not","requestBody":{"$ref":"#/components/requestBodies/Obj"},"response":{"200":{"description":"User exist already"}},"responses":{"default":{"description":"Default response"}}}}},"components":{"requestBodies":{"Obj":{"content":{"application/json":{"schema":{"type":"object","properties":{"email":{"type":"string"}}}}}}}}}
```

## POST /api/v2/login

> Endpoint for inviting user to organization

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"paths":{"/api/v2/login":{"post":{"description":"Endpoint for inviting user to organization","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"email":{"type":"string"},"password":{"type":"string"}}}}}},"responses":{"200":{"description":"JWT token for users(individual) and session token for org users"}}}}}}
```

## POST /api/v2/createUser

> Endpoint for registering a user

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"paths":{"/api/v2/createUser":{"post":{"description":"Endpoint for registering a user","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":"name email password userOTP","properties":{"name":{"type":"string"},"email":{"type":"string"},"password":{"type":"string"},"userOTP":{"type":"string"}}}}}},"responses":{"200":{"description":"User created successfully"}}}}}}
```

## POST /api/v2/forgotPassword

> Endpoint for sending mail to reset password

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"paths":{"/api/v2/forgotPassword":{"post":{"description":"Endpoint for sending mail to reset password","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":"email","properties":{"email":{"type":"string"}}}}}},"responses":{"200":{"description":"If an account exists for entered email, you will get an email with instructions on resetting your password. If it doesn't arrive, be sure to check your spam folder."}}}}}}
```

## GET /api/v2/viewProfile

> Endpoint for viewing user profile

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/viewProfile":{"get":{"description":"Endpoint for viewing user profile","responses":{"200":{"description":"User Profile"}}}}}}
```

## POST /api/v2/resetPassword

> Endpoint for resetting password for login user

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/resetPassword":{"post":{"description":"Endpoint for resetting password for login user","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["oldPassword","newPassword"],"properties":{"oldPassword":{"type":"string"},"newPassword":{"type":"string"}}}}},"description":"Profile object"},"responses":{"200":{"description":"Profile selected successfully"}}}}}}
```

## GET /api/v2/apiusageLogs

> Endpoint for getting all the logs used during apicall using API\_KEY

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/apiusageLogs":{"get":{"description":"Endpoint for getting all the logs used during apicall using API_KEY","responses":{"200":{"description":"API usage logs retrieved successfully"}}}}}}
```

## POST /api/v2/selectProfile

> Endpoint for selecting profile

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"paths":{"/api/v2/selectProfile":{"post":{"description":"Endpoint for selecting profile","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["sessionToken","userId"],"properties":{"sessionToken":{"type":"string"},"userId":{"type":"string"},"orgId":{"type":"string"}}}}},"description":"Profile object"},"responses":{"200":{"description":"Profile selected successfully"}}}}}}
```

## POST /api/v2/addOrgUser

> Endpoint for inviting user to organization

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/addOrgUser":{"post":{"description":"Endpoint for inviting user to organization","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"email":{"type":"string"},"role":{"type":"string"}}}}},"description":"User's email and role to assign (read, write, admin)"},"responses":{"200":{"description":"Invite sent successfully"}}}}}}
```

## POST /api/v2/updateOrgInvite

> Endpoint for updating already created invite

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/updateOrgInvite":{"post":{"description":"Endpoint for updating already created invite","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"role":{"type":"string"}}}}},"description":"role to assign (read, write, admin)"},"responses":{"200":{"description":"URL successfully uploaded"}}}}}}
```

## GET /api/v2/getOrgUsers

> Endpoint for getting all users in an organization

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/getOrgUsers":{"get":{"description":"Endpoint for getting all users in an organization","responses":{"200":{"description":"Users retrieved successfully"}}}}}}
```

## GET /api/v2/getOrgInvites

> Endpoint for getting all invites in an organization

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/getOrgInvites":{"get":{"description":"Endpoint for getting all invites in an organization","responses":{"200":{"description":"Invites retrieved successfully"}}}}}}
```

## POST /api/v2/updateOrgUser

> Endpoint for updating already created user

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/updateOrgUser":{"post":{"description":"Endpoint for updating already created user","requestBody":{"content":{"application/json":{"schema":{"type":"object","required":["userId","role"],"properties":{"userId":{"type":"string"},"role":{"type":"string"}}}}},"description":"user object"},"responses":{"200":{"description":"User updated successfully"}}}}}}
```

## DELETE /api/v2/deleteOrgUsers

> Endpoint for deleting multiple users from an organization

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/deleteOrgUsers":{"delete":{"description":"Endpoint for deleting multiple users from an organization","parameters":[{"in":"query","name":"userIds","description":"Comma separated list of user IDs to be deleted","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Users deleted successfully"}}}}}}
```

## POST /api/v2/createHooks

> Endpoint for creating hooks for an organization

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/createHooks":{"post":{"description":"Endpoint for creating hooks for an organization","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"discordWebhookUrl":{"type":"string","description":"URL for the Discord webhook"},"slackWebhookUrl":{"type":"string","description":"URL for the Slack webhook"}}}}},"description":"JSON object containing hook details","required":[]},"responses":{"200":{"description":"Hooks created successfully"}}}}}}
```

## POST /api/v2/generateApiKey

> Endpoint for generating API keys for an organization with expiration day

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/generateApiKey":{"post":{"description":"Endpoint for generating API keys for an organization with expiration day","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"expire":{"type":"integer","description":"Expiration period for the API key in days"}}}}},"description":"JSON object containing API key details","required":[]},"responses":{"200":{"description":"API key generated successfully"}}}}}}
```

## GET /api/v2/getApiKey

> Endpoint for getting API keys for an user or org

```json
{"openapi":"3.0.0","info":{"title":"JSMON API","version":"1.0.0"},"servers":[{"url":"https://api-dev.jsmon.sh","description":"Development Server (For internal testing)"},{"url":"https://api.jsmon.sh","description":"Production Server (Stable release)"}],"security":[{"Bearer":[]},{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-JSMON-KEY","description":"API Key to access the Jsmon API. Example: \"X-JSMON-KEY: your_api_key_here\""}}},"paths":{"/api/v2/getApiKey":{"get":{"description":"Endpoint for getting API keys for an user or org","responses":{"200":{"description":"API key generated successfully"}}}}}}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://knowledge.jsmon.sh/api-reference/reference/jsmon-api.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
