cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
3471
Views
1
Helpful
3
Replies

Content filtering

rares-pauna
Level 3
Level 3

Hello guys, i am trying to update the content filtering rules for all networks within a organization but i get this error

image.png

With a GET i took from a template the configuration for content filtering which i considered to be complete.

blockedUrlCategories=[
'meraki:contentFiltering/category/6',

'meraki:contentFiltering/category/10',

'meraki:contentFiltering/category/11',

'meraki:contentFiltering/category/13',

'meraki:contentFiltering/category/18',

'meraki:contentFiltering/category/27',

'meraki:contentFiltering/category/31',

'meraki:contentFiltering/category/32',

'meraki:contentFiltering/category/33',

'meraki:contentFiltering/category/36',
'meraki:contentFiltering/category/37',

'meraki:contentFiltering/category/46',

'meraki:contentFiltering/category/48',

'meraki:contentFiltering/category/49',

'meraki:contentFiltering/category/53',

'meraki:contentFiltering/category/54',
'meraki:contentFiltering/category/56',
'meraki:contentFiltering/category/57',
'meraki:contentFiltering/category/58',
'meraki:contentFiltering/category/59','meraki:contentFiltering/category/62','meraki:contentFiltering/category/64','meraki:contentFiltering/category/67','meraki:contentFiltering/category/68', 'meraki:contentFiltering/category/70','meraki:contentFiltering/category/71', 'meraki:contentFiltering/category/72','meraki:contentFiltering/category/73','meraki:contentFiltering/category/76'
],
urlCategoryListSize='fullList'
The same error i also get in postman
1 Accepted Solution

Accepted Solutions

After investigating i found that some categories disappeared, and the new syntax is 'meraki:contentFiltering/category/C1', there needs to be added " C " before the number. The name of the category is not needed in the POST, you only see it in the GET. So the solution is using " C".

View solution in original post

3 Replies 3

rares-pauna
Level 3
Level 3

I even tried with the example given on the developer hub :

dashboard.appliance.updateNetworkApplianceContentFiltering(
network_id,
allowedUrlPatterns=['http://www.example.org', 'http://help.com.au'],
blockedUrlPatterns=['http://www.example.com', 'http://www.betting.com'],
blockedUrlCategories=['meraki:contentFiltering/category/1', 'meraki:contentFiltering/category/7'],
urlCategoryListSize='topSites'
) , but i get the same error

Raphael_L
Meraki Community All-Star
Meraki Community All-Star

Have you tried to configure a simple content filtering policy on the dashboard , then retreived the rule via a GET ?https://developer.cisco.com/meraki/api-v1/#!get-network-appliance-content-filtering

Looking at the documentation , it seems that the output for categories is different from what you are using. It 'should' include the category name.

https://developer.cisco.com/meraki/api-v1/#!get-network-appliance-content-filtering-categories

After investigating i found that some categories disappeared, and the new syntax is 'meraki:contentFiltering/category/C1', there needs to be added " C " before the number. The name of the category is not needed in the POST, you only see it in the GET. So the solution is using " C".