Web

Request

Në shqip: Kërkesë

ShpjegimiSQ

Kërkesa është mesazhi që klienti i dërgon serverit për të marrë ose dërguar diçka. Ajo ka adresën (URL), llojin e veprimit (GET për të marrë, POST për të dërguar) dhe ndonjëherë të dhëna.

EnglishEN

A request is the message a client sends a server to get or send something. It has an address (URL), a type of action (GET to fetch, POST to send) and sometimes data.

Si ta mendosh

Si porosia që i jep kamarierit: „Dy porcione qebapa dhe një ajran, ju lutem.“ E qartë çfarë do dhe për cilën tavolinë.

Lexoje në anglisht

Like the order you give the waiter: “Two portions of kebabs and an ayran, please.” Clear what you want and which table it's for.

Shembull kodijavascript

fetch("https://api.example.com/porosite", {
  method: "POST",
  body: JSON.stringify({ ushqimi: "qebapa", sasia: 2 }),
});

Terma të lidhur