Types of API Flashcards

1
Q

REST

A

REST (Representational State Transfer) is an API style using stateless, client-server communication, typically over HTTP. It manipulates resources via standard methods (GET, POST, PUT, DELETE).

Example - A REST API for a bookstore might use /books (GET to view books) and /books/{id} (POST to add a book).

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

SOAP

A

SOAP (Simple Object Access Protocol) is a protocol for structured information exchange in web services, using XML over HTTP or SMTP.

Example - A SOAP API for weather might send XML requests to get temperature or humidity, with strict message format.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

RPC

A

RPC (Remote Procedure Call) is a protocol where a program requests a service or function execution on a remote server as if it were local.

Example - An RPC call might ask a remote server to perform calculations or retrieve data by calling getUserData() with parameters

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Local

A

A Local API provides communication between software components within the same system or device, without needing a network.

Example - An operating system API, like Windows API, allows applications to interact directly with system functions on the same machine.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly