Basic REST Architecture
What is a key characteristic of a RESTful API that improves scalability and reduces server-side complexity?
- Statelessness
- Sessionful connections
- Strong typing
- Fixed response structure only
- Client-maintained state
HTTP Methods and Resource Manipulation
Which HTTP method is commonly used to update an existing resource in a REST API?
- PUT
- DELETE
- FETCH
- CONNECT
- LIST
API Authentication Basics
In REST API integration, which protocol is typically used to securely obtain an access token before making requests?
- OAuth 2.0
- FTP
- Basic Authentication
- WebSockets
- SSH
Parsing API Data in Python
After making a GET request to a REST API in Python, what data format is most commonly parsed from the response?
- JSON
- YAML
- CSV
- TXT
- HTML
Making Requests with Access Tokens
When sending an authenticated request to a REST API, where should you typically include the access token?
- In the Authorization header
- In the URL path
- As the request body
- In the User-Agent header
- Inside the cookie
SOQL Usage and API Integration
What is the primary purpose of SOQL when used in REST API integration?
- Querying data from structured objects
- Synchronizing server sessions
- Enabling push notifications
- Writing CSS for API outputs
- Defining HTTP endpoints
Error Handling in REST APIs
If a REST API returns status code 404, what does this typically indicate?
- Resource not found
- Unauthorized access
- Successful creation
- Server timeout
- Invalid query syntax
Best Practices in Response Structure
Why is it important for REST APIs to return meaningful HTTP status codes and descriptive error messages?
- For easier debugging and API usability
- To speed up server hardware
- To ensure only XML is returned
- So the access token lasts longer
- To increase the number of API endpoints
API Versioning Approaches
Which method is commonly used to version a REST API to ensure backward compatibility?
- Including a version number in the URL path
- Changing the IP address of the server
- Removing error messages
- Switching to FTP protocol
- Using only numeric resource names
Advantages of RESTful Integration
What is a key benefit of integrating with a REST API in business applications?
- Automating data exchange between systems
- Restricting data to only local machines
- Preventing all user access
- Requiring manual data re-entry
- Limiting operations to text files