Search code examples
ibm-cloudcloud-foundry

Upload/Update XSP application to Bluemix through Cloud Foundry API


I'm using Cloud Foundry API to modify apps on IBM Bluemix. I got oauth key and succeeded in calling simple REST requests, like v2/apps. However, as I want to update XSP application I need to send a nsf file to bluemix.

I tried to use /v2/apps/:guid request, but according to documentation I can only send application parameters, but I cannot send whole application file.

Is there an endpoint to do that?


Solution

  • There is also an API to Upload the bits for an App, but if my understanding is correct what you are asking is basically to emulate a cf push via REST API. Please note that cf push is complex and is not something that is recommended recreating via API on Cloud Foundry. I don't know what your requirements are, but I'd suggest you to use cf push to do that. Anyway if you want more information on what are the steps it performs (from an high level perspective) you can take a look here. I suggest you also to see this Github Cloud Foundry issue where the user is trying to programmatically recreate the cf push.