ordercontext

package
v1.21.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 10, 2026 License: GPL-3.0 Imports: 2 Imported by: 0

Documentation

Overview

Package ordercontext carries the idempotency metadata of a V2 order creation through the request context into the order creators V1 and V2 share; a V1 request carries none.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ApplyIdempotency

func ApplyIdempotency(ctx context.Context, data *order.Order)

func GuestCheckoutToken

func GuestCheckoutToken(ctx context.Context) string

func WithIdempotency

func WithIdempotency(ctx context.Context, value Idempotency) context.Context

Types

type Idempotency

type Idempotency struct {
	Key                string
	Hash               string
	GuestCheckoutToken string
}

Idempotency carries V2-only creation metadata through the existing domain creators. V1 callers never attach it, so their persisted representation and behaviour remain unchanged.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL