2022
Panel |
---|
What is REST API? |
The ApiCode distribution REST API provide provides programmatic access to read and write 'Read' and 'Write' replication data. The REST API identifies the application and its users using OAUTH ; and, responses are available in jsonJSON. We have used SWAGGER editor for the end users to make the API calls so that they can try out APIs exposed by API management platform.
Click Herefor accessing to access the CW-API management platform for unregistered user.
Checklist Before Getting Started Started:
There are various API methods list which that are exposed for in this release , we . We will be adding more methods in the upcoming releases.
...
The ApiCpdeApiCode-Distribution distribution is an API which that is used to deploy ApiCode based rest on REST services from a git Git repository to the underlying ApiServerApi management server.
The Tables below tables explains the various model schema and model schemas and attributes which that form the model class
...
...
class:
Parameter | Description |
---|
Data Type |
---|
apiCodeServerUsername( |
optional) | The |
Salesforce
Username of the ApiCode server instance. | String |
apiCodeServerPassword(optional) | The |
FTP
Password of the ApiCode server instance. | String |
environment(optional) |
The salesfoce object to specify a file to be downloaded
String
...
User has the flexibility to define his/her environment in which s/he wishes to deploy the code base. | String |
Parameter | Description |
---|
Data Type |
---|
url( |
optional) | The |
Git repository url of the |
user from which |
string
password(Required)
The password of the salesforce instance
string
securityToken(Required)
A security Token is a case sensitive alpha numeric code that you append to the password or enter in a separate field in client application
string
sessionID(optional)
An Identifier for current user in the current context
string
endpointURL(Required)
The url to access the salesforce application
string
...
...
Parameter
Description
DataType
host(Required)
Hostname of ftp server
string
port(Required)
port number of ftp server
string
filesystemType
The possible supported FTP are Sftp, FTPS and plain FTP
string
username(Required)
ftp server username
string
password(Required)
ftp server password
string
folder(Required)
path within ftp server to place the file
he would like to deploy the code base. | String | |
branch(optional) | The branch inside of a repository from which the user wishes to deploy the code base. | String |
username(optional) | Valid User name of the Git repository | String |
password(optional) | Valid password of the Git repository | String |
Below table gives the attribute list of the response class
Parameter | Description | Data type |
Status
The possible values are True and False which sends out the response value
String
SubmitTime
The API submitted time
Date
CompletionTime
The API Completion Time
Date
ProcessID
The process id which is sent by the API to identify the process
String
callbackURL
The url is passed from the API
string
...
...
...
ServiceURL(optional) | The website url to access the service. | String |
docURL(optional) | Retrieves the URL of the file in the web layout directory. | Date |
SwaggerURL(optional) | The swagger url is the return type on which the response is listed. | Date |
status(optional) | The possible values are True and False. It sends out the response value. | String |
errorMessage(optional) | In case the status value is False, an error message is returned. | Array[string] |
Code Block |
---|
curl -X POST --header 'Content-Type: application/json' --header 'Accept: application/json' -d '{"sfConfigappCodeServerUsername":{"username":""anil.b@mydbsync.com","passwordappCodeServerPassword":"dbsync2015","securityTokenenvironment":"dev","sessionIdurl":"","endpointURL":""}, "fsConfig":{"host":"","port":"","filesystemType":"","username":"https://sureshullagaddi@bitbucket.org/dbsync/amazons3.git","branch":"dev","username":"suresh.u@avankia.com","password":"suresh@12345","folder":""},"queryToTheAttachment":""}' 'https://apistaging.mydbsync.com:443/api/appcode/v1/sftofilesystemappcode-distribution/upsertFilegitCompile' |
Code Block |
---|
https://apistaging.mydbsync.com:443/api/appcode/v1/sftofilesystem/upsertFile appcode-distribution/gitCompile. |
Code Block |
---|
{ "error": "AppCode:sftofilesystemappcode-distribution does not exist, Please check your URL". } |
Code Block |
---|
200. |
Code Block |
---|
{ "access-control-allow-origin": "*", "date": "MonFri, 2024 Feb 2017 1813:4423:54 GMT", "server": "Apache/2.4.25 (Amazon) OpenSSL/1.0.1k-fips", "connection": "Keep-Alive", "keep-alive": "timeout=5150, max=10092", "content-length": "7278", "content-type": "application/json" } |