# HTTP methods, status codes and REST constraints

*MuleSoft Integration Foundations Study Guide · Recognize and interpret essential integration concepts and terminology · Last updated November 2, 2026 · https://www.certifyforce.com/study-guide/mulesoft-integration-foundations/essential-integration-concepts-and-terminology/http-methods-status-codes-and-rest-constraints*

How a RESTful API uses HTTP: methods mapped to create, read, update and delete, URI parameters, query parameters and headers, the status codes that report success or failure, and the six REST constraints such as statelessness and cacheability.

- Certification: Salesforce MuleSoft Integration Foundations
- Exam section: Recognize and interpret essential integration concepts and terminology
- Study guide: https://www.certifyforce.com/study-guide/mulesoft-integration-foundations

**Official exam objective:**

> Identify and describe the HTTP components that enable RESTful web services.

## What the exam expects

- Pick the HTTP method that matches a create, read, update, partial update or delete requirement.
- Read a request line: resource path, URI parameter, query parameter, headers and body.
- Interpret common status codes (200, 201, 400, 401, 404, 500) and say whether the client or the server must act.
- Name the six REST constraints and recognize a design that breaks statelessness or cacheability.

Key terms:
- **REST**: Representational State Transfer, an architectural style of design constraints that usually runs over HTTP.
- **Resource and URI**: the data a REST API exposes, each piece reached through a Uniform Resource Identifier.
- **URI parameter**: a path segment that identifies one specific resource.
- **Query parameter**: a name-value pair after the `?` that refines the request.
- **Statelessness**: the server keeps no session information about the client between requests.

## Key facts

| Fact | Detail | Source |
|---|---|---|
| PUT vs PATCH | PUT replaces the whole resource; PATCH modifies specific fields | [What is REST](https://www.mulesoft.com/api/rest/what-is-rest-api) |
| POST success | 201 Created | [Perform API Calls](https://trailhead.salesforce.com/content/learn/modules/application-networks-and-api-led-connectivity-in-mulesoft/perform-api-calls) |
| Missing required body field | 400 Bad Request | [Perform API Calls](https://trailhead.salesforce.com/content/learn/modules/application-networks-and-api-led-connectivity-in-mulesoft/perform-api-calls) |
| Missing credentials | 401 Unauthorized | [Perform API Calls](https://trailhead.salesforce.com/content/learn/modules/application-networks-and-api-led-connectivity-in-mulesoft/perform-api-calls) |
| Missing resource | 404; reserve 500 for server crashes | [What is REST](https://www.mulesoft.com/api/rest/what-is-rest-api) |
| Mocking service | Returns example success responses, even for incomplete requests | [Perform API Calls](https://trailhead.salesforce.com/content/learn/modules/application-networks-and-api-led-connectivity-in-mulesoft/perform-api-calls) |
| Optional REST constraint | Code-on-demand is the only one | [What is REST](https://www.mulesoft.com/api/rest/what-is-rest-api) |
| Where state lives in REST | On the client, never the server | [REST API design](https://www.mulesoft.com/resources/api/what-is-rest-api-design) |
| Preferred payload format | JSON | [What is REST](https://www.mulesoft.com/api/rest/what-is-rest-api) |

## Check yourself

- Why does REST put the action in the HTTP method rather than in the path?
- When does APIkit's generated error handling return 405?
- Why does statelessness make horizontal scaling simple?
- Which REST constraint lets an API gateway sit between client and server unnoticed?

## Sources

- [What is a REST (RESTful) API?](https://www.mulesoft.com/api/rest/what-is-rest-api)
- [What is REST API design?](https://www.mulesoft.com/resources/api/what-is-rest-api-design)
- [Examine APIs and Web Services (Trailhead)](https://trailhead.salesforce.com/content/learn/modules/application-networks-and-api-led-connectivity-in-mulesoft/examine-apis-and-web-services)
- [Perform API Calls (Trailhead)](https://trailhead.salesforce.com/content/learn/modules/application-networks-and-api-led-connectivity-in-mulesoft/perform-api-calls)
- [APIkit for REST Error Handling Reference](https://docs.mulesoft.com/apikit/latest/apikit-error-handling-reference)
- [Client ID Enforcement Policy](https://docs.mulesoft.com/mule-gateway/policies-included-client-id-enforcement)

## About the full unit

The "Core concepts", "Exam traps" and "Worked scenario" sections of this unit, its 4 linked practice questions, and unlimited timed mock exams are included with the MuleSoft Integration Foundations pack (USD $19): https://www.certifyforce.com/practice-exams
