Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Code Integration Scenarios

R Convenience Functions

"Level 1" functions

"Level 2" functions

Web Services

These manipulation only the metadata, stored in Synapse.
Note: It is assumed that code versions are represented by refererences.

Create Code

Code Block

POST https://repo-staging.sagebase.org/repo/v1/code
{"parentId":"1234", "srcRepoId":"4567", "srcRepoLoc":"/trunk/analysisProject/R"}

Note: "parentId" is the ID of a Synapse Project; "srcRepoId" is the ID of a Source Repository object.

Successful Response:

Code Block

HTTP/1.1 201 Created
{"id":"8901", "parentId":"1234", "srcRepoId":"4567", "srcRepoLoc":"/trunk/analysisProject/R"}

Get Code

Code Block

GET https://repo-staging.sagebase.org/repo/v1/code/8901

Successful Response:

Code Block

HTTP/1.1 200 OK
{"id":"8901", "parentId":"1234", "srcRepoId":"4567", "srcRepoLoc":"/trunk/analysisProject/R"}

Update Code

Code Block

PUT https://repo-staging.sagebase.org/repo/v1/code/8901
{"id":"8901", "parentId":"5432", "srcRepoId":"4567", "srcRepoLoc":"/trunk/analysisProject/R"}

Successful Response:

Code Block

HTTP/1.1 200 OK
{"id":"8901", "parentId":"5432", "srcRepoId":"4567", "srcRepoLoc":"/trunk/analysisProject/R"}

Delete Code

Code Block

DELETE https://repo-staging.sagebase.org/repo/v1/code/8901

Successful Response:

Code Block

HTTP/1.1 204 No Content

Scenarios