agency-time

POST /v1/agency/time/projects/from-quote

Start a project from a free-quote request.

Tất cả các điểm cuối agency-time

Tất cả tài liệu dành cho nhà phát triển

Xác thực

Gửi khóa API dưới dạng mã thông báo bearer. Khóa này phải có quyền agency.time.manage; khóa không có quyền này sẽ bị từ chối với mã lỗi 403, không phải 404.

Nơi điền id tổ chức của bạn

Endpoint này nhận org_id làm một trường trong phần thân JSON.

Mã tổ chức của bạn nằm ở màn hình khóa API trong bảng điều khiển, ngay bên cạnh khóa đó. Đây là cùng một mã trong mọi lệnh gọi mà bạn thực hiện.

Dùng thử

Thay thế bất kỳ nội dung nào trong ngoعل (angle brackets) bằng giá trị của riêng bạn và trình giữ chỗ key bằng một key từ trang tổng quan của bạn.

curl -X POST https://api.zinndigital.com/v1/agency/time/projects/from-quote \
  -H "Authorization: Bearer zdk_live_…" \
  -H "Content-Type: application/json" \
  -d '{ "quote_id": <string> }'

Đã đăng nhập? Bảng điều khiển API trong trang quản lý của bạn sẽ tự điền ID tổ chức thực tế và khóa của riêng bạn, sau đó chạy yêu cầu đối với API trực tiếp để bạn có thể xem phản hồi thực tế. Mở điểm cuối này trong bảng điều khiển API

Chi tiết

Zinn Digital®'s own organisation only (docs/670 §2). In one transaction: the requester becomes a client (found by e-mail, or created, carrying the request's country), a project board is opened with the brief, a time project is linked to both in the quoted currency, the quoted price becomes a fixed-price task, and the request is marked won — which is what stops the admin queue's charge conversion and the draft-from-quote invoice billing the same job again. Requires agency.time.manage in the organisation and the quotes.manage staff permission the admin queue requires. Idempotent per request: a second call returns the project the first one made, with created: false.

Nội dung yêu cầu

TênLoạiBắt buộcNội dung này là gì
quote_idstring
amount_minorintegerKhôngThe agreed price, NET, in minor units — only for a request that has not been priced. On a priced request omit it; a different figure is refused.
currencystringKhông
countrystringKhôngThe client's ISO-2 country, used only when the request carries none (the public form does not ask). The bill on the checkout needs it; anything but two letters is refused.
org_idstringKhông

Phản hồi

TênLoạiBắt buộcNội dung này là gì
projectTimeProject
board_idstring
client_idstring
createdbooleanFALSE when a project for this request already existed and was returned.
price_already_billed_onstringKhôngThe reference of a bill already drafted straight from this request, when there was one — in which case the project carries no fixed price, because that bill charges it.

Các lỗi điểm cuối này có thể trả về

401 · 403 · 422