cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Announcements

Cisco ACI automation postman

1237
Views
0
Helpful
8
Comments
MaazJaved2649
Beginner

Hi,

 

I am trying to create multiple subnets in one bridge domain using postman for ACI automation. I want to know if there is a document specific to the automation mentioned above. Can someone help me with this please. I am using global variables for subnet and also created the CSV with subnets to be added in the bridge domain in which when I run the postman collection runner tool with the csv I created, I get a status code of 200 for the first Rest api call followed by status code 400 for every other api call.  

8 Comments

Please Share your script,which you are using,I will check it whether you are using right script or not

MaazJaved2649
Beginner

image.jpg

 

image.jpg

Hi I have attached my script that I’m trying to use and also the csv that has the subnets to be created using the runner tool. Please take a look at it. 

Hi MaazJaved,

I have tested the below script and it is working,please verify and let me know.

 

 

{"fvSubnet":{"attributes":{"dn":"uni/tn-KK/BD-test-BD/subnet-[{{subnet}}]","ctrl":"","ip":"{{subnet}}","scope":"public","rn":"subnet-[{{subnet}}]","status":"created"},"children":[]}}

 

 

Regards,

K.Kolanji

MaazJaved2649
Beginner

image.jpg

 

image.jpg


hi, I ran the script you posted you can see the first image and I got the same issue a  status code of 200 for the first subnet followed by status code of 400 for the other subnets api call. 

Hi,

I have tested again in the same script,it is working fine.

Please add manually one subnet and share the API inspector script.

 

Thanks,

K.Kolanji

MaazJaved2649
Beginner

Hi here is the api inspector code for adding one subnet manually.

 

method: POST

url: https://10.6.188.100/api/node/mo/uni/tn-Test_postman2/BD-MC_Test_BD/subnet-[10.6.188.150/30].json

 

payload{"fvSubnet":{"attributes":{"dn":"uni/tn-Test_postman2/BD-MC_Test_BD/subnet-[10.6.188.150/30]","ctrl":"","ip":"10.6.188.150/30","rn":"subnet-[10.6.188.150/30]","status":"created"},"children":[{"fvRsBDSubnetToProfile":{"attributes":{"tnL3extOutName":"default","status":"created,modified"},"children":[]}}]}}

MaazJaved2649
Beginner

I’m trying to figure out why the runner tool is generating status code 200 for the first api call which is successful in creating the first subnet, but then for all the remaining calls a status code of 400. 

Hi,

The Script seems to be fine but it is stange,why it is not working for you.

Please try following method

======================= 

1.When you running script,please select login option as well.

2.Check your postman enviornemnt options and settings,whether you properly configured

 

Thanks,

K.Kolanji