บันทึกการเปลี่ยนแปลง API

รายการเพิ่มและเปลี่ยนแปลง API ของ ReceiptRoller เรียงจากใหม่ไปเก่า "ต้องดำเนินการ" หมายถึงการเปลี่ยนแปลงที่การเชื่อมต่อของคุณอาจต้องปรับตาม

ติดตามผ่าน RSS

ตุลาคม 2569

  • ข้อกำหนด

    Numbers published as numbers

    636 numeric fields were published as integer|string; they are now plain numbers. The API never returns a number as a string. Requests still accept numeric strings.

  • เพิ่ม

    Edit the signed-in user's profile

    PATCH /api/v1/me changes the display name, language and time zone, and POST /api/v1/me/avatar replaces the profile image, under user.profile.write. If any field is rejected, the profile is left unchanged.

  • ข้อกำหนด

    Both shapes of /sales/kpis and /sales/trend published

    With storeId these endpoints return the store shape (revenue, transactionCount, …); without it, the business-account shape (totalRevenue, …). The spec showed only the latter; both are now published as oneOf.

  • ข้อกำหนด

    Documented responses, 401 and 403 in the spec

    Every operation that takes a token now lists 401, and 403 naming its scope. Success codes such as 204 are published as they are returned. No endpoint behaves differently.

  • ต้องดำเนินการ

    Webhooks are signed with the webhook's secret

    Deliveries were signed with the client ID, not the webhook secret the docs describe. They are now signed with the secret; if you verify with the client ID, switch to the secret. receipt.created is now sent once per new sale, and X-RR-Delivery stays the same across retries.

  • ข้อกำหนด

    Token-only operations marked in the spec

    Operations that need a token but no particular scope (/me, devices, webhook management, …) now carry a security entry with no scopes. An operation without one needs no token. /api/sns/crm/* and the creative API, which use the site's sign-in cookie, left the spec.

  • เพิ่ม

    Create and manage posts (お知らせ)

    /api/v1/organizations/{organizationId}/posts lists (drafts and scheduled included), reads, creates, updates, publishes, archives and deletes posts, under the new store.posts.read / store.posts.write scopes.

  • เพิ่ม

    Google reviews and insights

    /api/v1/google-business lists unanswered reviews, replies, drafts an AI reply and reads a store's insights, under sns.content.read / sns.content.write. Store details and weekly hours changed through the API now also update the linked Google listing.

  • เพิ่ม

    Token verify returns the business account

    POST /api/v1/auth/verify now returns organizationId: the business account the token is bound to, or null for a user token. The field is additive, so existing clients are unaffected.

  • ต้องดำเนินการ

    Store role levels enforced on transactions, reservations and customers

    Being placed at a store used to open all of its API. Store roles now apply: staff view reservations and the day's transactions; shift leads also see earlier transactions, book, run slots and look customers up; store managers also change customers. "The day" is Japan's. Business-account roles are unchanged.

  • เพิ่ม

    Coupons and store-email settings for users

    Users' coupons can now be claimed, used and un-used through the API under user.coupons.write; refusals carry the reason as 409 (already_used, …). Store-email settings are readable and writable at /api/v1/user/store-mail.

  • ต้องดำเนินการ

    Receipt writes need user.receipts.write

    The 18 write operations in the user receipt APIs (receipts, categories, labels, scan, statements, QR claim) ran on user.receipts.read. They now require the new user.receipts.write; user.receipts.read is still accepted on them for two weeks.

  • ข้อกำหนด

    Parameter descriptions and the real error body in the spec

    32 parameter descriptions that were written but dropped are now published. 4xx bodies reference ApiError ({ error }), the shape actually returned; 400 also lists ProblemDetails from model validation.

  • ต้องดำเนินการ

    Business-account roles reach all stores only in their own area

    Any business-account role used to open every area of the store API. Each area now names the roles that reach every store, matching the web screens; outside its area, a role holder keeps only the stores they are placed at.

  • ต้องดำเนินการ

    Business-account endpoints return only the caller's stores

    Someone placed at one store could list other stores' customers, orders, sales and staff. Transactions, orders, inventory, staff and customers are now limited to the caller's stores; products show only the caller's prices and no cost. Business-account roles and integration tokens see what they did. Purchase-history take is capped at 200.

กันยายน 2569

  • เปลี่ยนแปลง

    /api/v1/me says why it refuses

    /api/v1/me returned empty 403s. They now carry no_user_context for a token without a user, and not_a_member for a user who is not an active member. Status codes are unchanged.

  • ต้องดำเนินการ

    Reading a store's sales needs a role that runs the store

    Any token with sales.read could read a store's revenue, churn scores and advice with ?storeId= if its user was merely placed there. A role that runs the store is now required; business-account tokens still pass. Every operation's required scope is now declared in the spec.