الترويسات المهمة لمهندسي الواجهة الخلفية
في هذا الدرس 4 موضوعات
هذا الدرس مخطط له. يعرض المخطط أدناه الموضوعات التي سيغطيها، ولم يُنشر الدرس الكامل بعد.
نص الدروس والتمارين باللغة الإنجليزية، بينما تبقى واجهة الموقع وعناوين الدروس بالعربية.
في هذا الدرس
know the handful of headers you will use every week.
الموضوعات المخطط لها
- Headers are
Name: valuepairs sent before the body, in both requests and responses. Content-Typesays what the body is.Content-Lengthsays how big it is.Authorizationcarries credentials.Locationgives the URL of a created resource.User-AgentandHostidentify the client and the target server.- Header names are case-insensitive; never put secrets in URLs, use headers instead.
تفاصيل المخطط المبدئي
عرض عملي
POST /products HTTP/1.1
Host: localhost:8080
Content-Type: application/json
Authorization: Bearer <token>
{"name":"Pen","priceCents":150}اختبر فهمك
Which response header tells the client where the new resource lives?
أظهر الإجابة
Location.
التطبيق
طبّق هذا الدرس بمختبر الوحدة وتمارينها واختبارها.
تعليم الدرس كمكتمل اختياري ويمكنك التراجع عنه في أي وقت. يبقى تقدمك محفوظًا في هذا المتصفح.