F5 Sites
  • F5.com
  • F5 Labs
  • MyF5
  • NGINX
  • Partner Central
  • Education Services Portal (ESP)
Contact
  • Under Attack?
  • F5 Support
  • DevCentral Support
  • F5 Sales
  • NGINX Sales
  • F5 Professional Services
Skip to contentBrand Logo
Forums
CrowdSRC
Articles
GroupsEventsSuggestionsHow Do I...?
RegisterSign In
  1. DevCentral
  2. Articles
  3. Technical Articles

iControl REST 101 – Creating Objects

If you’ve been following along so far you’ve gotten an idea about what iControl REST is all about, seen how to get up and running so you can send commands via cURL to the API, parsed some responses, ...
Published Feb 20, 2014
Version 1.0
BIG-IP Access Policy Manager (APM)
cloud
deployment
devops
iControl
icontrol rest 101
iControlREST
management
security
TMSH
Colin_Walker_12's avatar
Colin_Walker_12
Historic F5 Account
Joined May 12, 2005
View Profile
Riley_Schuit_82's avatar
Riley_Schuit_82
Historic F5 Account
Nov 06, 2014
A little late but, Tewfik: surround your message body with single quotes. Example: Fails: $ curl -s -k -u admin:admin -H "Accept: application/json" -H "Content-type: application/json" -X POST -d "{"name":"cw_test2","address":"10.10.10.4/8","vlan":"internal2"}" https://172.24.130.88/mgmt/tm/net/self Output: {"code":400,"message":"Found invalid JSON body in the request.","errorStack":[]} Succeeds: $ curl -s -k -u admin:admin -H "Accept: application/json" -H "Content-type: application/json" -X POST -d '{"name":"cw_test4","address":"10.10.10.5/8","vlan":"internal2"}' https://172.24.130.88/mgmt/tm/net/self Output: {"kind":"tm:net:self:selfstate","name":"cw_test4","fullPath":"cw_test4","generation":1106,"selfLink":"https://localhost/mgmt/tm/net/self/cw_test4?ver=11.5.0","address":"10.10.10.5/8","floating":"disabled","inheritedTrafficGroup":"false","trafficGroup":"/Common/traffic-group-local-only","unit":0,"vlan":"/Common/internal2"}

Help guide the future of your DevCentral Community!

What tools do you use to collaborate? (1min - anonymous)

ABOUT DEVCENTRAL

DevCentral NewsTechnical ForumTechnical ArticlesTechnical CrowdSRCCommunity GuidelinesDevCentral EULAGet a Developer Lab LicenseBecome a DevCentral MVP

RESOURCES

Product DocumentationWhite PapersGlossaryCustomer StoriesWebinarsFree Online CoursesTraining & Certification

SUPPORT

Manage SubscriptionsProfessional ServicesCreate a Service RequestSoftware DownloadsSupport Portal

PARTNERS

Find a Reseller PartnerTechnology AlliancesBecome an F5 PartnerLogin to Partner Central

©2026 F5, Inc. All rights reserved.
TrademarksPoliciesPrivacyCalifornia PrivacyDo Not Sell My Personal Information