This repository has been archived on 2026-03-21. You can view files and clone it, but cannot push or open issues or pull requests.
payfrit-biz/api/beacons/list_all.cfm
John Mizerek be29352b21 Migrate beacon APIs to shard-only system
- save.cfm: Auto-allocates shard+Major to business, creates ServicePoint with Minor
- list.cfm: Lists ServicePoints with BeaconMinor (removed legacy Beacons table)
- list_all.cfm: Returns shard UUIDs instead of legacy beacon UUIDs
- lookup.cfm: Removed legacy UUID lookup, shard-only resolution

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-14 19:33:49 -08:00

29 lines
635 B
Text

<cfsetting showdebugoutput="false">
<cfsetting enablecfoutputonly="true">
<cfcontent type="application/json; charset=utf-8" reset="true">
<cfheader name="Cache-Control" value="no-store">
<!--- No auth required - returns all Payfrit shard UUIDs for beacon scanning --->
<cfquery name="q" datasource="payfrit">
SELECT ID, UUID
FROM BeaconShards
WHERE IsActive = 1
ORDER BY ID
</cfquery>
<cfset items = []>
<cfloop query="q">
<cfset arrayAppend(items, {
"ShardID" = q.ID,
"UUID" = q.UUID
})>
</cfloop>
<cfoutput>#serializeJSON({
"OK" = true,
"ERROR" = "",
"SHARDS" = items,
"ITEMS" = items
})#</cfoutput>