Forum Discussion
Journeys API Assistance for loading UCS file as source
Looking for assisatnce with Journeys API Endpoint
POST - https://<hostname>/sessions/{session_id}/source.
Looking to load ucs file, Swagger details these requirements (see below) but all attempts end up with error saying ucs file must be specified. Looking for someone to provide a working example please
Thanks
Simon
session_id * integer (path) |
Request body
UCS and Optional passphrase
ucs_file string($binary) | |
ucs_passphrase string | |
as3_file string($binary) | |
username string | |
password string($password) | |
host string | |
master_key string |
Hi iasimov,
You can use an asynchronous task to create a UCS using REST
From the REST API User Guide you can try following
Using Python (3) You could use the following (code generated by Postman):
import http.client
conn = http.client.HTTPConnection("192,168,25,42")payload = "{\"command\": \"save\",\"name\": \"myUcs\"}"
headers = {
'X-F5-Auth-Token': "ABCDEFG",
'Content-Type': "application/json",
}conn.request("POST", "mgmt,tm,task,sys,ucs", payload, headers)
res = conn.getresponse()
data = res.read()print(data.decode("utf-8"))
https://cdn.f5.com/websites/devcentral.f5.com/downloads/icontrol-rest-api-user-guide-14-1-0.pdf
https://clouddocs.f5.com/f5-aci-servicecenter/latest/rest_api.html
https://community.f5.com/t5/technical-forum/restoring-ucs-archive-using-rest-api/td-p/297493
There could be a possibility of a known issue with BIG-IP sometimes, the UCS creation with passphrase isn't working with admin user.
https://cdn.f5.com/product/bugtracker/ID791365.html
Here is the workaround:
This affects users logged in with the Admin role; you will be able to create a UCS with a passphrase while logged in as either the root user or as a user with the resource-admin role.
Reference Topics¶
If you’re looking to browse through some of the capabilities of iControl REST, here are some reference topics that will help get you on your way. The User Guide is of particular interest as it is jam packed with examples and deep dive information that should answer darn near any question you might have while getting started.- API Listing By Version -
- API Reference - iControl REST API Reference Documentation
- APIRef_tm_ltm_pool_members -
- New In Version 12.1.0 - Changes in iControl REST for BIG-IP version 12.1.0
- New In Version 13.0.0 - Changes in iControl REST for BIG-IP version 12.1.0
- iControl REST User Guide Version 11.5 (PDF)
- iControl REST User Guide Version 11.6 (PDF)
- iControl REST User Guide Version 12.0 (PDF)
- iControl REST User Guide Version 12.1 (PDF)
- iControl REST User Guide Version 13.0 (PDF)
- iControl REST User Guide Version 13.1 (PDF)
- iControl REST User Guide Version 14.1 (PDF)
- iControl REST User Guide Version 15.1 (PDF) (Note: this guide is also applicable to version 16.0)
- iControl REST User Guide Version 16.1 (PDF) (Note: this guide is also applicable to version 17.0)
- Application Visibility and Reporting (AVR) REST API, Version 1.0 (PDF)
- iControl REST for BIG-IP Advanced Firewall Manager Version 11.6 (PDF)
HTH
🙏
- iasimovNimbostratus
Thanks for the reply HTH, but this has nothing to with creating a UCS file. I want to use a UCS file as the source for the journeys migration tool (which I can do through the GUI) but I want to do through the API. I am looking for an example as I can not seem to get the syntax correct for this one call (see above)
POST - https://<hostname>/sessions/{session_id}/source.
All the other calls to the journeys API are working correctly...just looking for an example to help me out
Thanks
Simon
Recent Discussions
Related Content
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com