2022

Page tree

Versions Compared

Key

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

...

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 Here for accessing to access the CW-API management platform for unregistered user.

Checklist Before Getting Started Started: 

  1. user User should have the release of 4.2.9 or later.
  2. Have a valid credentials of DBSync API management platform platform. 
  3. Have a valid credentials of bitbucket.

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. 

...

ApiCode-Distribution

The ApicodeApiCode-distribution is an API which that is used to deploy Apicode ApiCode based rest on REST services from a git Git repository to the underlying Api management server.

The Tables below tables explains the various model schema and model schemas and attributes which that form the model class class: 

...

ApiCode Server Params

Parameter

Description

Data Type

apiCodeServerUsername(optional)

The

username

Username of the ApiCode server instance.

string

String

apiCodeServerPassword(optional)

The

password

Password of the ApiCode server instance.

string 

String 

environment(optional)

User has the flexibility to define his/her environment in which s/he wishes to deploy

his

the code base.

string

String

Git Repository Params

Parameter

Description

Data Type

url(optional)

The

git

Git repository url of the user from which he would like to deploy the code base.

string

String

branch(optional)

The branch inside of a repository from which the user wishes to deploy the code base.

string

String

username(optional)

Valid

user

User name of the

git

Git repository

string

String

password(optional)

Valid password of the

git

Git repository

string

String

Run Properties Params

Below table gives the attribute list of the response class

Parameter

Description

Data type

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 

listed. 

Date

status(optional)

The possible values are True and False

which

. It sends out the response value.

String

errorMessage(optional)

In case

of

the status value is False, an error message is

returned 

returned. 

Array[string]

Example

...

of an Unsuccessful Deployment
Curl
Code Block

curl -X POST --header 'Content-Type: application/json' --header 'Accept: application/json' -d '{"appCodeServerUsername":"anil.b@mydbsync.com","appCodeServerPassword":"dbsync2015","environment":"dev","url":"https://sureshullagaddi@bitbucket.org/dbsync/amazons3.git","branch":"dev","username":"suresh.u@avankia.com","password":"suresh@12345"}' 'https://staging.mydbsync.com:443/api/appcode/v1/appcode-distribution/gitCompile'

Request URL
Code Block

https://staging.mydbsync.com:443/api/appcode/v1/appcode-distribution/gitCompile.
Response Body
Code Block

{
  "error": "AppCode:appcode-distribution does not exist, Please check your URL".
}
Response Code
Code Block
  200.
Response Header
Code Block

{
 "access-control-allow-origin": "*",
 "date": "Fri, 24 Feb 2017 13:23:54 GMT",
 "connection": "Keep-Alive",
 "keep-alive": "timeout=150, max=92","content-length": "78",
 "content-type": "application/json"
}