A JavaScript client for Atlassian Stash's REST API, utilizing Promises.
Installation
From npm:
npm install stasher
The library and its dependencies are compatible with browserify.
Usage
All API methods return Promises/A+ compatible promises via Bluebird.
let stasher = let client = base_url: 'http://dockerhost:32833/stash' auth: type: stashAuthTypeBASIC username: 'user' password: 'pass' { console console} clientprojects clientprojects clientrepositories
Current Status
Work in progress.
- Error handling
- OAuth
- Core API
- Projects
-
GET /rest/api/1.0/repos
-
GET /rest/api/1.0/projects
-
GET /rest/api/1.0/projects/{key}
-
GET /rest/api/1.0/projects/{key}/repos
-
GET /rest/api/1.0/projects/{key}/repos/{repo}
-
GET /rest/api/1.0/projects/{key}/repos/{repo}/tags
-
GET /rest/api/1.0/projects/{key}/repos/{repo}/forks
-
GET /rest/api/1.0/projects/{key}/repos/{repo}/related
-
GET /rest/api/1.0/projects/{key}/repos/{repo}/branches
-
GET /rest/api/1.0/projects/{key}/repos/{repo}/branches/default
-
GET /rest/api/1.0/projects/{key}/repos/{repo}/browse
-
GET /rest/api/1.0/projects/{key}/repos/{repo}/browse/{path}
-
GET /rest/api/1.0/projects/{key}/repos/{repo}/changes
-
GET /rest/api/1.0/projects/{key}/repos/{repo}/commits
-
GET /rest/api/1.0/projects/{key}/repos/{repo}/commits/{id}
-
GET /rest/api/1.0/projects/{key}/repos/{repo}/commits/{id}/changes
-
GET /rest/api/1.0/projects/{key}/repos/{repo}/commits/{id}/comments
-
GET /rest/api/1.0/projects/{key}/repos/{repo}/files
-
GET /rest/api/1.0/projects/{key}/repos/{repo}/pull-requests
-
GET /rest/api/1.0/projects/{key}/repos/{repo}/pull-requests/{id}
-
GET /rest/api/1.0/projects/{key}/repos/{repo}/pull-requests/{id}/activities
-
GET /rest/api/1.0/projects/{key}/repos/{repo}/pull-requests/{id}/changes
-
GET /rest/api/1.0/projects/{key}/repos/{repo}/pull-requests/{id}/comments
-
GET /rest/api/1.0/projects/{key}/repos/{repo}/pull-requests/{id}/commits
-
GET /rest/api/1.0/projects/{key}/repos/{repo}/pull-requests/{id}/diff
-
GET /rest/api/1.0/projects/{key}/repos/{repo}/pull-requests/{id}/participants
-
- Profile
-
GET /rest/api/1.0/profile/recent/repos
-
- Users
-
GET /rest/api/1.0/users
-
GET /rest/api/1.0/users/{slug}
-
- Projects
- Build Integration API