A nodejs server that recieve files and commit them to github repo
npm install
npm start
POST
the payload (below) tohttp//localhost:3000/commit
Recommended way - git clone
and deploy with a ci system
(such as
.
Read the guide)
POST
this payload:
{
"remoteRepo": "{owner}/{repository_name}",
"token": "{personal_access_token}",
"commitMessage": "{commit_message}",
"files": [
{
"path": "path/to/first-file.txt",
"content": "content of first-file.txt"
},
{
"path": "path/to/second-file.txt",
"content": "content of second-file.txt"
}
]
}
personal_access_token
- Meant to allow the server to commit on your behalf. How do I get this token?