<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Bad request: There was a problem in the JSON you submitted error - Code Help in Network Platform API</title>
    <link>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450558#M7860</link>
    <description>&lt;P&gt;No.&lt;/P&gt;</description>
    <pubDate>Wed, 05 May 2021 20:18:21 GMT</pubDate>
    <dc:creator>Austin_Campbell</dc:creator>
    <dc:date>2021-05-05T20:18:21Z</dc:date>
    <item>
      <title>Bad request: There was a problem in the JSON you submitted error - Code Help</title>
      <link>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450548#M7850</link>
      <description>&lt;P&gt;I am creating a script for mass l7 firewall changes and I am running into an error. My code is below. I have made sure that my layer7rules.json file is properly formatted in json. &lt;/P&gt;&lt;PRE&gt;&lt;SPAN&gt;import &lt;/SPAN&gt;requests&lt;BR /&gt;&lt;SPAN&gt;import &lt;/SPAN&gt;json&lt;BR /&gt;&lt;SPAN&gt;import &lt;/SPAN&gt;os&lt;BR /&gt;&lt;SPAN&gt;from &lt;/SPAN&gt;dotenv &lt;SPAN&gt;import &lt;/SPAN&gt;load_dotenv&lt;BR /&gt;&lt;BR /&gt;load_dotenv()&lt;BR /&gt;api_key = os.environ.get(&lt;SPAN&gt;"API_Key"&lt;/SPAN&gt;)&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;with &lt;/SPAN&gt;&lt;SPAN&gt;open&lt;/SPAN&gt;(&lt;SPAN&gt;"layer7rules.json"&lt;/SPAN&gt;) &lt;SPAN&gt;as &lt;/SPAN&gt;f:&lt;BR /&gt;    payload = json.load(f)&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;with &lt;/SPAN&gt;&lt;SPAN&gt;open&lt;/SPAN&gt;(&lt;SPAN&gt;"testnetids.txt"&lt;/SPAN&gt;) &lt;SPAN&gt;as &lt;/SPAN&gt;file:&lt;BR /&gt;    array = file.readlines()&lt;BR /&gt;    &lt;SPAN&gt;for &lt;/SPAN&gt;line &lt;SPAN&gt;in &lt;/SPAN&gt;array:&lt;BR /&gt;        line = line.rstrip(&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN&gt;\n&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;)&lt;BR /&gt;    url = &lt;SPAN&gt;"https://api.meraki.com/api/v0/networks/%s/l7FirewallRules" &lt;/SPAN&gt;% line&lt;BR /&gt;    headers = {&lt;BR /&gt;        &lt;SPAN&gt;'Content-Type'&lt;/SPAN&gt;: &lt;SPAN&gt;'application/json'&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;        &lt;SPAN&gt;'X-Cisco-Meraki-API-Key'&lt;/SPAN&gt;: api_key&lt;BR /&gt;    }&lt;BR /&gt;&lt;BR /&gt;response = requests.request(&lt;SPAN&gt;"PUT"&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;url&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;headers&lt;/SPAN&gt;=headers&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;data&lt;/SPAN&gt;=payload)&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;print&lt;/SPAN&gt;(response.text)&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 05 May 2021 19:32:08 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450548#M7850</guid>
      <dc:creator>Austin_Campbell</dc:creator>
      <dc:date>2021-05-05T19:32:08Z</dc:date>
    </item>
    <item>
      <title>Re: Bad request: There was a problem in the JSON you submitted error - Code Help</title>
      <link>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450549#M7851</link>
      <description>&lt;P&gt;&lt;A href="https://community.meraki.com/t5/user/viewprofilepage/user-id/60145"&gt;@Austin_Campbell&lt;/A&gt; : I think the below code from your script should be in &lt;SPAN&gt;double quotes. What error message you are getting ?&lt;/SPAN&gt;&lt;/P&gt;&lt;PRE&gt;headers = {&lt;BR /&gt;        &lt;SPAN&gt;'Content-Type'&lt;/SPAN&gt;: &lt;SPAN&gt;'application/json'&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;        &lt;SPAN&gt;'X-Cisco-Meraki-API-Key'&lt;/SPAN&gt;: api_key&lt;BR /&gt;    }&lt;/PRE&gt;</description>
      <pubDate>Wed, 05 May 2021 19:46:17 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450549#M7851</guid>
      <dc:creator>inderdeepsingh1</dc:creator>
      <dc:date>2021-05-05T19:46:17Z</dc:date>
    </item>
    <item>
      <title>Re: Bad request: There was a problem in the JSON you submitted error - Code Help</title>
      <link>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450550#M7852</link>
      <description>&lt;P&gt;I am getting the error "Bad request: There was a problem in the JSON you submitted". Tried with double quotes same result. Here is my json file.&lt;/P&gt;&lt;PRE&gt;{&lt;BR /&gt;    &lt;SPAN&gt;"rules"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;[&lt;BR /&gt;        {&lt;BR /&gt;            &lt;SPAN&gt;"policy"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"deny"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;            &lt;SPAN&gt;"type"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"blacklistedCountries"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;            &lt;SPAN&gt;"value"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;[&lt;BR /&gt;                &lt;SPAN&gt;"CN"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;                &lt;SPAN&gt;"CU"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;                &lt;SPAN&gt;"HK"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;                &lt;SPAN&gt;"ID"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;                &lt;SPAN&gt;"IR"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;                &lt;SPAN&gt;"LY"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;                &lt;SPAN&gt;"LT"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;                &lt;SPAN&gt;"MY"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;                &lt;SPAN&gt;"MX"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;                &lt;SPAN&gt;"NE"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;                &lt;SPAN&gt;"KP"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;                &lt;SPAN&gt;"PK"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;                &lt;SPAN&gt;"RU"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;                &lt;SPAN&gt;"SC"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;                &lt;SPAN&gt;"KR"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;                &lt;SPAN&gt;"SY"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;                &lt;SPAN&gt;"TW"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;                &lt;SPAN&gt;"TH"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;                &lt;SPAN&gt;"TR"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;                &lt;SPAN&gt;"UA"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;                &lt;SPAN&gt;"AE"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;                &lt;SPAN&gt;"YE"&lt;BR /&gt;&lt;/SPAN&gt;            ]&lt;BR /&gt;        }&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;        {&lt;BR /&gt;            &lt;SPAN&gt;"policy"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"deny"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;            &lt;SPAN&gt;"type"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"ipRange"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;            &lt;SPAN&gt;"value"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"80.82.77.139/32"&lt;BR /&gt;&lt;/SPAN&gt;        }&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;        {&lt;BR /&gt;            &lt;SPAN&gt;"policy"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"deny"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;            &lt;SPAN&gt;"type"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"ipRange"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;            &lt;SPAN&gt;"value"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"149.202.120.37/32"&lt;BR /&gt;&lt;/SPAN&gt;        }&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;        {&lt;BR /&gt;            &lt;SPAN&gt;"policy"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"deny"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;            &lt;SPAN&gt;"type"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"ipRange"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;            &lt;SPAN&gt;"value"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"208.91.197.27/32"&lt;BR /&gt;&lt;/SPAN&gt;        }&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;        {&lt;BR /&gt;            &lt;SPAN&gt;"policy"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"deny"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;            &lt;SPAN&gt;"type"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"ipRange"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;            &lt;SPAN&gt;"value"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"217.174.152.68/32"&lt;BR /&gt;&lt;/SPAN&gt;        }&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;        {&lt;BR /&gt;            &lt;SPAN&gt;"policy"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"deny"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;            &lt;SPAN&gt;"type"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"ipRange"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;            &lt;SPAN&gt;"value"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"193.56.28.125/32"&lt;BR /&gt;&lt;/SPAN&gt;        }&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;        {&lt;BR /&gt;            &lt;SPAN&gt;"policy"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"deny"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;            &lt;SPAN&gt;"type"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"ipRange"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;            &lt;SPAN&gt;"value"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"92.242.140.21/32"&lt;BR /&gt;&lt;/SPAN&gt;        }&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;        {&lt;BR /&gt;            &lt;SPAN&gt;"policy"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"deny"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;            &lt;SPAN&gt;"type"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"ipRange"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;            &lt;SPAN&gt;"value"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"185.165.190.34/32"&lt;BR /&gt;&lt;/SPAN&gt;        }&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;        {&lt;BR /&gt;            &lt;SPAN&gt;"policy"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"deny"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;            &lt;SPAN&gt;"type"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"ipRange"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;            &lt;SPAN&gt;"value"&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;"223.71.167.163/32"&lt;BR /&gt;&lt;/SPAN&gt;        }&lt;BR /&gt;    ]&lt;BR /&gt;}&lt;/PRE&gt;</description>
      <pubDate>Wed, 05 May 2021 19:54:36 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450550#M7852</guid>
      <dc:creator>Austin_Campbell</dc:creator>
      <dc:date>2021-05-05T19:54:36Z</dc:date>
    </item>
    <item>
      <title>Re: Bad request: There was a problem in the JSON you submitted error - Code Help</title>
      <link>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450551#M7853</link>
      <description>&lt;P&gt;&lt;A href="https://community.meraki.com/t5/user/viewprofilepage/user-id/60145"&gt;@Austin_Campbell&lt;/A&gt; : Your Jason seems correct, Check and validate below your script.&lt;/P&gt;&lt;P&gt;&lt;A href="https://jsonlint.com/" target="_blank" rel="nofollow noopener noreferrer"&gt;https://jsonlint.com/&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 05 May 2021 19:58:34 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450551#M7853</guid>
      <dc:creator>inderdeepsingh1</dc:creator>
      <dc:date>2021-05-05T19:58:34Z</dc:date>
    </item>
    <item>
      <title>Re: Bad request: There was a problem in the JSON you submitted error - Code Help</title>
      <link>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450552#M7854</link>
      <description>&lt;P&gt;&lt;A href="https://community.meraki.com/t5/user/viewprofilepage/user-id/60145"&gt;@Austin_Campbell&lt;/A&gt; : Change the URL as well fron v0 to v1 as well.&lt;/P&gt;&lt;PRE&gt;url = &lt;SPAN&gt;"https://api.meraki.com/api/v0/networks&lt;/SPAN&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 05 May 2021 19:59:30 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450552#M7854</guid>
      <dc:creator>inderdeepsingh1</dc:creator>
      <dc:date>2021-05-05T19:59:30Z</dc:date>
    </item>
    <item>
      <title>Re: Bad request: There was a problem in the JSON you submitted error - Code Help</title>
      <link>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450553#M7855</link>
      <description>&lt;P&gt;Thanks for the link. I tested and it does pass as valid json. &lt;/P&gt;</description>
      <pubDate>Wed, 05 May 2021 20:00:44 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450553#M7855</guid>
      <dc:creator>Austin_Campbell</dc:creator>
      <dc:date>2021-05-05T20:00:44Z</dc:date>
    </item>
    <item>
      <title>Re: Bad request: There was a problem in the JSON you submitted error - Code Help</title>
      <link>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450554#M7856</link>
      <description>&lt;P&gt;and also &lt;SPAN&gt;Replace the base URL with the actual shard you are on. Google script does not seem to follow the redirect. E.g. &lt;/SPAN&gt;&lt;A href="https://n248.meraki.com/api" target="_blank" rel="nofollow noopener noreferrer"&gt;https://n248.meraki.com/api&lt;/A&gt;&lt;SPAN&gt;.... instead of &lt;/SPAN&gt;&lt;A href="https://api.meraki.com/" target="_blank" rel="nofollow noopener noreferrer"&gt;https://api.meraki.com&lt;/A&gt;&lt;SPAN&gt; ... More info about that issue here: &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://documentation.meraki.com/General_Administration/Other_Topics/Cisco_Meraki_Dashboard_API#Status_and_Error_Codes" target="_blank" rel="nofollow noopener noreferrer"&gt;https://documentation.meraki.com/General_Administration/Other_Topics/Cisco_Meraki_Dashboard_API#Status_and_Error_Codes&lt;/A&gt; &lt;/P&gt;</description>
      <pubDate>Wed, 05 May 2021 20:01:22 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450554#M7856</guid>
      <dc:creator>inderdeepsingh1</dc:creator>
      <dc:date>2021-05-05T20:01:22Z</dc:date>
    </item>
    <item>
      <title>Re: Bad request: There was a problem in the JSON you submitted error - Code Help</title>
      <link>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450555#M7857</link>
      <description>&lt;P&gt;I have tried this as well no luck with v0 or v1 same error. &lt;/P&gt;</description>
      <pubDate>Wed, 05 May 2021 20:02:09 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450555#M7857</guid>
      <dc:creator>Austin_Campbell</dc:creator>
      <dc:date>2021-05-05T20:02:09Z</dc:date>
    </item>
    <item>
      <title>Re: Bad request: There was a problem in the JSON you submitted error - Code Help</title>
      <link>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450556#M7858</link>
      <description>&lt;P&gt;No luck with this change either. I believe this to be a specific problem with the python script and the way I am loading the json file into the api call.&lt;/P&gt;</description>
      <pubDate>Wed, 05 May 2021 20:07:18 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450556#M7858</guid>
      <dc:creator>Austin_Campbell</dc:creator>
      <dc:date>2021-05-05T20:07:18Z</dc:date>
    </item>
    <item>
      <title>Re: Bad request: There was a problem in the JSON you submitted error - Code Help</title>
      <link>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450557#M7859</link>
      <description>&lt;P&gt;Can you use Post method ?&lt;/P&gt;</description>
      <pubDate>Wed, 05 May 2021 20:16:43 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450557#M7859</guid>
      <dc:creator>inderdeepsingh1</dc:creator>
      <dc:date>2021-05-05T20:16:43Z</dc:date>
    </item>
    <item>
      <title>Re: Bad request: There was a problem in the JSON you submitted error - Code Help</title>
      <link>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450558#M7860</link>
      <description>&lt;P&gt;No.&lt;/P&gt;</description>
      <pubDate>Wed, 05 May 2021 20:18:21 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450558#M7860</guid>
      <dc:creator>Austin_Campbell</dc:creator>
      <dc:date>2021-05-05T20:18:21Z</dc:date>
    </item>
    <item>
      <title>Re: Bad request: There was a problem in the JSON you submitted error - Code Help</title>
      <link>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450559#M7861</link>
      <description>&lt;P&gt;Try setting up one entry exactly how you would like in the dashboard, then 'get' those settings and look at the json return.  In fact, you should be able to use that json for your future put calls.&lt;/P&gt;</description>
      <pubDate>Wed, 05 May 2021 23:23:57 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450559#M7861</guid>
      <dc:creator>Philip D'Ath</dc:creator>
      <dc:date>2021-05-05T23:23:57Z</dc:date>
    </item>
    <item>
      <title>Re: Bad request: There was a problem in the JSON you submitted error - Code Help</title>
      <link>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450560#M7862</link>
      <description>&lt;P&gt;The json file that I have was produced from a postman meraki api "get" of our standard l7 rules. I am able to use a json.dump of the exact json I have above and it works successfully for a "put".&lt;/P&gt;</description>
      <pubDate>Thu, 06 May 2021 14:46:06 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450560#M7862</guid>
      <dc:creator>Austin_Campbell</dc:creator>
      <dc:date>2021-05-06T14:46:06Z</dc:date>
    </item>
    <item>
      <title>Re: Bad request: There was a problem in the JSON you submitted error - Code Help</title>
      <link>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450561#M7863</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Much easier is it like this :&lt;/P&gt;&lt;DIV&gt;&lt;SPAN&gt;def Create_L7_Firewall(def_network):&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;    if new_class_type == "C":&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;        try:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;            with open('Vessel-C-SDtraffic-L7.json') as my_file:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;                my_SD_traffic = json.load(my_file)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;        except:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;            print ("File Vessel-C-SDtraffic-L7.json not found")&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;    elif new_class_type == "B":&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;        try:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;            with open('C:\\Scripts\\Create BC Vessel\\Vessel-B-SDtraffic-L7.json') as my_file:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;                my_SD_traffic = json.load(my_file)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;        except:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;            print ("File Vessel-B-SDtraffic-L7.json not found")&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;    response = dashboard.appliance.updateNetworkApplianceFirewallL7FirewallRules(def_network,**my_SD_traffic)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;P&gt;We have Class B and C vessels..... each Class has a different set of rules...&lt;/P&gt;&lt;P&gt;Just read the json file and push it into the network&lt;/P&gt;&lt;P&gt;Best regards&lt;/P&gt;&lt;P&gt;Ed&lt;/P&gt;</description>
      <pubDate>Tue, 11 May 2021 10:31:12 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450561#M7863</guid>
      <dc:creator>Edgar-VO</dc:creator>
      <dc:date>2021-05-11T10:31:12Z</dc:date>
    </item>
    <item>
      <title>Re: Bad request: There was a problem in the JSON you submitted error - Code Help</title>
      <link>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450562#M7864</link>
      <description>&lt;P&gt;Thank you for your suggestion. I was able to figure out the issue and the code is working. I had to add data=json.dumps(payload) because json.load() strips the double quotations required for json when converting the file to a python dictionary.  &lt;/P&gt;</description>
      <pubDate>Tue, 11 May 2021 13:52:05 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-platform-api/bad-request-there-was-a-problem-in-the-json-you-submitted-error/m-p/5450562#M7864</guid>
      <dc:creator>Austin_Campbell</dc:creator>
      <dc:date>2021-05-11T13:52:05Z</dc:date>
    </item>
  </channel>
</rss>

