Skip to main content
API Reference SwiftyNsdk NsdkVpsSession

anchorPayload

Gets the payload data of a specified anchor....

Declaration

func anchorPayload(anchorId: NsdkVpsAnchorId) -> NsdkAsyncState<String, Never>?

Summary

Gets the payload data of a specified anchor.
The payload encodes the data needed to localize an anchor across multiple devices or sessions.
It can be shared or stored for later use with trackAnchor(payload:).
Payloads are only available after the anchor is tracked.
- Precondition: anchorId must be exactly 32 characters long.
- Parameter anchorId: The unique identifier of the anchor
- Returns: An AnchorTrackingBound representing the state of the anchor payload request:
- .inProgress(nil): The anchor is not yet tracked, so the payload is not yet available.
- .success(Value): The request completed successfully. Contains the base64-encoded payload.
- nil: No anchor with id anchorId was found.


ON THIS PAGE