第一次看此系列文的朋友,請先移步到 Day 1 – 如何開始?進行方式、自我介紹實戰 哦!
今天的情境是你在與前端工程師合作開發新功能。當 API 還沒完成,而前端需要先串接假資料測試時,雙方需要對接 API 規格。這時候經常卡住在「怎麼清楚說明資料格式、狀態碼、或命名差異」上。
今日目標:能清楚解釋後端 API 的設計與資料結構。
因為我是從 Backend Engineer 出發來撰寫的今天的練習
所以你如果不是 Backend 的話,就抱歉了😭
[Config]
- Day: Day21 – Frontend Collaboration
- Scenario: You’re a backend engineer discussing an API design with a frontend developer. You need to explain the endpoint, request/response structure, and error handling clearly.
記得把對話錄下來,自己聽一次,想想有哪裡不自然、哪裡需要調整。
解釋 API 目的
說明 input/output 結構
userId
as the key.描述狀態碼或錯誤處理
與前端協作確認
🤖 Which screen needs this API, and main user action?
🗣️ When the user wants to place the order, they use the API to insert the order into the order book.
🤖 The request will be a simple JSON with the order details. The response will confirm success or show an error if something goes wrong.
🗣️ Exactly, and you have to carry the cookie for authorization.
這邊我不太知道怎麼說比較好,所以我後來有問 GPT,母語者會怎麼說?
他給了我兩個說法
We just include the cookie in the request for auth
or simply,We just send the cookie along for authorization
🤖 We'll talk a bit more about how we handle errors next.
🗣️ Okay, when the request parameter is empty, I will return the bad request parameter, like 400. And in the other situation, I just response the 500 for internal service error.
GPT 給的母語者口語說法
If something's missing, we throw a 400 error. If there's a bigger issue, we just send a 500.
🗣️ How the front-end team handle the login. Like, you guys use the cookie or use the authorization token?
GPT 給的母語者口語說法
So do you guys handle login with cookies or tokens?
1) Per-turn Corrections
Turn 2: You said: "He use this API to insert the order to the order book."
Rewrite: "They use this API to insert the order into the order book."
Alternative: "They use this API to add the order into the order book."
Turn 4: You said: "You have to carry the cookie for the authorization."
Rewrite: "You have to carry the cookie for authorization."
Alternative: "You need to include the cookie to authorize."
Turn 6: You said: "When the request parameter is empty, and I'll return the bad request parameter like 400."
Rewrite: "When the request parameter is empty, I'll return a bad request status like 400."
Alternative: "If the request parameter is empty, I’ll just send back a 400 error."
Turn 8: You said: "How the frontend team handle the login."
Rewrite: "How the frontend team handles the login."
Alternative: "How the frontend team deals with login."
2) Top 3 Patterns
Subject-verb agreement: Sometimes missing the 's' in verbs for he/she/it.
Rule: Remember: "He/she/it adds an s-fit!"
Article usage: Occasionally missing "a" or "the."
Mnemonic: Think of articles as tiny arrows: "a/the" points to the noun.
Prepositions: Occasionally missed "into" or mixed up "to" and "into."
Tip: Use "into" for movement inside something, like "insert into the book."
3) Phrase Pack
"We use this API to..."
"You need to include the cookie for authorization."
"If the parameter is empty, we return a 400 error."
"Let’s talk about how you handle login."
"We also return 500 for internal errors."
4) Intonation Tip
Tip: Emphasize the key nouns. For example, in "We return a 400 error," stress "400 error" to highlight the important detail.
5) Fluency & Pronunciation Notes
Overall fluency is good; just keep sentences short and steady.
Watch article use ("a"/"the") in front of nouns.
Good job repeating corrected sentences.
6) Key Focus for Next Time
Goals: Practice article usage, prepositions ("to" vs "into"), and maintaining subject-verb agreement.