300-435 · Question #4
Which REST endpoint is used to create a Cisco Meraki network?
The correct answer is A. POST /organizations/{organizationId}/networks. To create a new network within a specific organization in Cisco Meraki, the API uses a POST request to the /organizations/{{organizationId}}/networks endpoint.
Question
Options
- APOST /organizations/{organizationId}/networks
- BPATCH /networks/{networkId}
- CPUT /organizations/{organizationId}/networks
- DPOST /networks/{networkId}
How the community answered
(24 responses)- A96% (23)
- C4% (1)
Why each option
To create a new network within a specific organization in Cisco Meraki, the API uses a POST request to the `/organizations/{{organizationId}}/networks` endpoint.
According to REST API best practices and Cisco Meraki API documentation, creating a new resource (like a network) under a parent resource (an organization) typically uses a POST request to the collection endpoint of the child resource, which is `/organizations/{{organizationId}}/networks`.
PATCH requests are used to partially update an existing resource, not to create a new one.
PUT requests are generally used for replacing an entire resource or creating a resource if it doesn't exist at a specific, known URI, which is not the typical pattern for creating new networks where the ID is usually assigned by the server.
POST to `/networks/{{networkId}}` implies either acting on a specific existing network or creating a network with a client-defined ID, which is not the standard Meraki API pattern for creating a new network and associating it with an organization.
Concept tested: Cisco Meraki API network creation endpoint
Source: https://developer.cisco.com/meraki/api-v1/#!create-organization-network
Topics
Community Discussion
No community discussion yet for this question.