syndesisio / syndesis-rest

The API for Syndesis - a flexible, customizable, cloud-hosted platform that provides core integration capabilities as a service. It leverages Red Hat's existing product architecture using OpenShift Online/Dedicated and Fuse Integration Services.
https://syndesis-staging.b6ff.rh-idev.openshiftapps.com/api/v1/
Apache License 2.0
6 stars 17 forks source link
api camel ipaas java kubernetes openshift redhat swagger

Repos moved

This repository is not longer active and has been moved to https://github.com/syndesisio/syndesis (code & issues)


Syndesis REST API

Codacy Badge CircleCI AppVeyor Maven Central Dependency Status

Swagger

Swagger

Building

mvn clean install

Start a PostgreSQL DB in a Docker container

docker run -d --rm \ -p 5432:5432 \ -e POSTGRES_USER=postgres \ -e POSTGRES_PASSWORD=password \ -e POSTGRES_DB=syndesis \ postgres

Deploying to Kubernetes

oc login <KUBERNETES_MASTER>
cd runtime
mvn clean package fabric8:build fabric8:deploy fabric8:start

Endpoints

There is a staging URL on OpenShift dedicated that you can test with, along with the Swagger JSON Swagger UI.

This demo endpoint has some preloaded data and can be used for testing and demoing purposes.

Authentication

The REST API is protected via an OAuth 2.0 Bearer Token. The REST API server is a resource server as defined in The OAuth 2.0 Authorization Framework: Bearer Token Usage. This requires all requests include a valid access token in the Authorization header of the request (there are other methods but they are discouraged). The header should look like:

Authorization: Bearer MDQyODExLCJpc3MiOi...

Roland's random notes

eval $(minishift docker-env)
cd runtime
mvn fabric8:build -Dfabric8.mode=kubernetes

Ignore warning about not being able to remove old image.

oc delete pod $(oc get pods | awk '{ print $1 }' | grep syndesis-rest)
oc edit cm syndesis-rest-config
TOKEN="...."
curl -k -v https://syndesis.192.168.64.3.xip.io/api/v1/integrations -H "Authorization: Bearer $TOKEN" -H "Accept: application/json" -H "Content-Type: application/json" -d '{ "name": "syndesis-test-repo" }'
oc port-forward $(oc get pods | awk '{ print $1 }' | grep syndesis-rest) 8000:8000