Read cross-publication reader records and memberships ending on a date
Read publication summaries for a reader’s memberships or assigned ticket passes, or find memberships ending on one calculated date. Each route has a different credential and publication scope.
| Task | Operation | Allowed credentials |
|---|---|---|
| Read membership records with publication summaries | GET /api/v1/admin/users/{user_id}/subscriptions/resources | admin or partner, or root |
| Read assigned active passes with event/publication summaries | GET /api/v1/admin/users/{user_id}/tickets/resources | admin or partner, or root |
| Select memberships ending on one calculated date | GET /api/v1/admin/resources/{key}/memberships/before-end-subscription | Eligible existing service account, or root; ordinary Admin roles do not enable it |
A subscription is a catalog choice in a Plan; a membership links an account to that choice. A ticket pass can have different owning and assigned accounts. These reads do not grant access, renew memberships, send mail or prove payment.
Existing credentials, identifiers and example conventions
Use the API address and existing credentials supplied by your operator.
| Input | Transport / context | Meaning |
|---|---|---|
| token | Header for the two reader-summary reads | ADMIN_TOKEN must be an existing admin-or-inherited credential, or root context. These reads have no service-account action grant; full_access alone cannot enable them. |
| resource | Header when used for the caller’s existing context; included in reader examples | Publication public key. Reader summaries describe account-wide records across publications; use resource_key or resource_keys for the intended publication selection. For the service-account date read, it resolves the existing credential context. Not a numeric publication ID or private secret. |
| service-api-key | Header for the date read | Existing active, non-suspended service account with active attached user and eligibility for this exact action through its existing permissions. Ordinary ADMIN_TOKEN is not the example credential for this route. |
| user_id | Digits-only reader path value | Reader ID from your intended account records. An empty summary does not establish whether the account exists. |
| key | Publication path value on the date read | Public key selecting the target publication. Example uses the same intended key in path and header. |
Shared caller/session restrictions apply. Choose the intended reader and publication from your existing records. Keep privileged requests in trusted server code.
Examples use fictional IDs and illustrative responses. Requests use cURL, Node.js 18+ fetch in an ES module (.mjs), and Python 3 urllib. Set WALLKIT_API_BASE to scheme and host only. Reader summaries use existing RESOURCE_KEY and ADMIN_TOKEN; date selection uses an eligible SERVICE_API_KEY. Replace EXAMPLE_PUBLICATION_KEY with the intended public key. For date selection, use that same key in path and header, encoding the path segment as needed.
Publication details in reader summaries
Reader summaries return only the fields listed below. Values follow stored types unless explicitly converted to boolean. Missing related records can leave null fields; extra may remain JSON text. Monetary units and timestamp timezone are unspecified.
Both summaries include this five-field resource object:
| Field | Meaning / stored type |
|---|---|
| id | Publication identifier, not an account ID. |
| title | Stored publication display text. |
| key | Public publication key, not a private secret. |
| host | Stored publication host text; not a reachability check. |
| active | Stored active flag; these summaries do not require it to be true. |
Read an account’s memberships with publication summaries
GET /api/v1/admin/users/{user_id}/subscriptions/resources
Read membership-associated rows for a shared reader account across publications. For a selected-publication task, supply its intended resource_key, or use resource_keys for several intended publications.
Before you call
Use an admin-or-inherited token, or root, and the intended reader ID from your account records. Returned memberships can be inactive or expired, and catalog choices, Plans or publications can be inactive or private. These are stored relationships, rather than proof of payment or access.
Request
Send the path, headers and optional publication filters without a body. Results are unpaginated, with unspecified order; no sort or date-range option is supported.
| Query input | Type / requirement | Meaning |
|---|---|---|
| resource_key | Optional public-key string | Exact joined-publication key match. Minimal example uses one known intended key. |
| resource_keys | Optional comma-separated public-key string | Multiple joined-publication key matches. No explicit trimming/deduplication/empty-token validation guarantee. |
If both publication filters are supplied, both apply. Omitting both returns the account-wide selection. Use exact intended publication keys and inspect the returned publication context.
Response fields
HTTP 200 returns items containing subscription, plan and the five-field resource summary above. There is no paginator, account wrapper or membership relationship-row ID.
subscription contains:
| Field | Meaning / stored type |
|---|---|
| id | Catalog subscription identifier, not membership relationship ID. |
| title | Current catalog title text. |
| description | Current catalog description text. |
| subscriber_type | Stored catalog subscriber category; no closed enum inferred. |
| plan_id | Catalog choice’s Plan reference; may differ from the separate membership-Plan join if data is inconsistent. |
| price | Stored catalog amount; currency units unspecified, no conversion applied. |
| currency | Stored currency text for price. |
| period | Stored catalog period, not a computed remaining membership duration. |
| active | Stored catalog active flag, not a filter or final access decision. |
| once | Stored single-use catalog flag. |
| private | Stored catalog visibility flag; not filtered here. |
| trial_period | Stored catalog trial-period setting, not current trial eligibility. |
| extra | Stored catalog extra value; may remain stored JSON text/null rather than decoded object. |
| subscription_end_date | Membership expiration timestamp or null. |
| subscription_start_date | Membership row creation timestamp, not catalog creation. |
| subscription_updated_date | Membership row update timestamp. |
| autorenew | Boolean membership renewal choice. |
| is_trial | Boolean membership trial marker. |
| is_team_subscription | Boolean membership team marker. |
plan contains:
| Field | Meaning / stored type |
|---|---|
| id | Membership’s joined Plan identifier. |
| resource_id | Plan’s stored publication reference. |
| slug | Stored Plan slug text. |
| title | Current Plan title text. |
| description | Current Plan description text. |
| full_access | Stored Plan full-access flag, not a final reader access result. |
| active | Stored Plan active flag, not filtered here. |
| priority | Stored Plan priority value. |
| private | Stored Plan visibility flag, not filtered here. |
| can_own_teams | Stored Plan team-ownership setting, not a caller role. |
| extra | Stored Plan extra; may remain stored JSON text/null. |
Joined records can be missing or inconsistent. Inspect unexpected or inconsistent catalog and membership-Plan associations with your operator. There are no next/downgrade, VAT, sponsored-slot or profile fields. The older membership list returns different fields and uses a different publication scope.
Example: Read membership records for the intended publication
Replace the placeholder with the intended publication key. The response excerpt omits other fields defined above.
curl "${WALLKIT_API_BASE}/api/v1/admin/users/1002/subscriptions/resources" \
-X GET \
-H "resource: ${RESOURCE_KEY}" \
-H "token: ${ADMIN_TOKEN}" \
--get \
--data-urlencode 'resource_key=EXAMPLE_PUBLICATION_KEY'
const url = new URL(`${process.env.WALLKIT_API_BASE}/api/v1/admin/users/1002/subscriptions/resources`);
url.search = new URLSearchParams({"resource_key": "EXAMPLE_PUBLICATION_KEY"}).toString();
const response = await fetch(url, {
method: "GET",
headers: {"resource": process.env.RESOURCE_KEY, "token": process.env.ADMIN_TOKEN}
});
console.log(response.status, await response.json());
import os, json
from urllib.request import Request, urlopen
from urllib.error import HTTPError
from urllib.parse import urlencode
url = os.environ["WALLKIT_API_BASE"] + "/api/v1/admin/users/1002/subscriptions/resources"
url += "?" + urlencode({'resource_key': 'EXAMPLE_PUBLICATION_KEY'})
request = Request(
url,
headers={"resource": os.environ["RESOURCE_KEY"], "token": os.environ["ADMIN_TOKEN"]},
method="GET"
)
try:
with urlopen(request) as response:
print(response.status, json.load(response))
except HTTPError as error:
print(error.code, json.load(error))
HTTP 200 response excerpt:
{
"items": [
{
"subscription": {
"id": 3001,
"title": "Example subscription",
"plan_id": 5001,
"subscription_start_date": "2026-10-01 12:00:00",
"subscription_end_date": "2026-11-07 12:00:00",
"autorenew": false,
"is_trial": false,
"is_team_subscription": false
},
"plan": {
"id": 5001,
"resource_id": 2001,
"title": "Example Plan"
},
"resource": {
"id": 2001,
"title": "Example publication",
"key": "EXAMPLE_PUBLICATION_KEY",
"host": "example.com",
"active": true
}
}
]
}
The catalog ID is not a membership row ID. A returned relationship does not establish payment or current content access.
No membership summaries are returned
HTTP 200 response:
{
"items": []
}
No matches, an unknown account, missing publication joins, filter behavior or a caught query failure can all return empty items. Do not treat it as a definitive absence of memberships.
Recovery
| HTTP status | API code / response shape | Cause | Next action |
|---|---|---|---|
| 200 | items [] | No matching rows or a caught processing exception. | Check the intended account/publication filter. Investigate unexpected emptiness with the integration operator instead of treating it as proven absence. |
| Varies / no guaranteed JSON | Other PHP/transport failure | Failure response formats can vary. | Retain any request reference and ask the integration operator to inspect the failure. |
See shared errors. Display relationships with publication context, or use the older membership list for its selected-publication scope.
Read active passes assigned to the account
GET /api/v1/admin/users/{user_id}/tickets/resources
Read active passes assigned to this account, with ticket, event and publication details. This is not every ticket owned or bought by the account. Results can span publications; select the intended publication with resource_key.
Before you call
Use an admin-or-inherited token, or root, and the intended reader ID from your account records. Pass, ticket and event must be active; the publication can be inactive. Supply the intended resource_key for a selected-publication task.
Request
Send the path, headers and supported query inputs without a body. Results are unpaginated; no sort option is supported.
| Query input | Type / requirement | Meaning |
|---|---|---|
| resource_key | Optional public-key string | Exact joined-publication key match. |
| resource_keys | Optional comma-separated public-key string | Multiple joined-publication key matches; when singular key is also supplied, both apply. No explicit trim/dedup/empty-token validation guarantee. |
| only_available | Optional boolean-filtered value; default false | When true, removes rows whose event end is earlier than now in that event’s timezone (UTC fallback when null). This is not a full availability/entry check. |
Omitting both publication filters adds no publication restriction. only_available evaluates the event end; determine selling-window availability, capacity, pass usage and entry permission separately. Invalid row timezone data can cause an empty result even without that option.
Response fields
HTTP 200 returns items with these four nested objects. There is no paginator or expanded account/organizer identity. resource uses the five-field definition above.
ti_event_ticket_pass:
| Field | Meaning / stored type |
|---|---|
| id | Ticket-pass identifier, distinct from ticket/event IDs. |
| owner_id | Stored pass owner account; can differ from the assigned account. |
| assign_id | Assigned account ID, used to match the path reader. |
| active | Stored pass active flag, required true by this query; not proof of unused/entry eligibility. |
ti_event_ticket:
| Field | Meaning / stored type |
|---|---|
| id | Catalog ticket identifier. |
| slug | Stored ticket slug text. |
| title | Current ticket title text. |
| description | Current ticket description text. |
| price | Stored ticket price; units unspecified. |
| currency | Stored currency text; no conversion. |
| status | Stored ticket status; no closed enum inferred. |
| start_date | Stored ticket window start, not enforced by only_available. |
| end_date | Stored ticket window end, not the event-end comparison. |
| active | Stored ticket active flag, required true. |
| is_private | Stored ticket privacy flag, not filtered here. |
ti_event:
| Field | Meaning / stored type |
|---|---|
| id | Event identifier, distinct from ticket/pass IDs. |
| title | Current event title text. |
| description | Current event description text. |
| location | Stored location text. |
| timezone | Event timezone used for the event-end comparison; UTC fallback if null. |
| registration_page | Stored registration-page value, not a tested reachable page. |
| url | Stored event URL value, not a tested reachable page. |
| contact_email | Stored contact address, not sender identity or evidence of mail delivery. |
| status | Stored event status; no closed enum inferred. |
| start_date | Stored event start; only_available does not require it to have arrived. |
| end_date | Stored event end compared against current event-local time when only_available is true. |
| is_virtual | Stored virtual-event flag. |
Selection checks event activity without returning its active flag. No scan/QR/authentication code, auth link, usage count or admission decision is included.
Example: Read assigned passes whose event has not ended
The intended publication is explicit. owner_id: 1003 differs from assign_id: 1002; assignment selects this row. Other ticket/event fields are omitted from the excerpt.
curl "${WALLKIT_API_BASE}/api/v1/admin/users/1002/tickets/resources" \
-X GET \
-H "resource: ${RESOURCE_KEY}" \
-H "token: ${ADMIN_TOKEN}" \
--get \
--data-urlencode 'resource_key=EXAMPLE_PUBLICATION_KEY' \
--data-urlencode 'only_available=true'
const url = new URL(`${process.env.WALLKIT_API_BASE}/api/v1/admin/users/1002/tickets/resources`);
url.search = new URLSearchParams({"resource_key": "EXAMPLE_PUBLICATION_KEY", "only_available": "true"}).toString();
const response = await fetch(url, {
method: "GET",
headers: {"resource": process.env.RESOURCE_KEY, "token": process.env.ADMIN_TOKEN}
});
console.log(response.status, await response.json());
import os, json
from urllib.request import Request, urlopen
from urllib.error import HTTPError
from urllib.parse import urlencode
url = os.environ["WALLKIT_API_BASE"] + "/api/v1/admin/users/1002/tickets/resources"
url += "?" + urlencode({'resource_key': 'EXAMPLE_PUBLICATION_KEY', 'only_available': 'true'})
request = Request(
url,
headers={"resource": os.environ["RESOURCE_KEY"], "token": os.environ["ADMIN_TOKEN"]},
method="GET"
)
try:
with urlopen(request) as response:
print(response.status, json.load(response))
except HTTPError as error:
print(error.code, json.load(error))
HTTP 200 response excerpt:
{
"items": [
{
"ti_event_ticket_pass": {
"id": 6101,
"owner_id": 1003,
"assign_id": 1002,
"active": true
},
"ti_event_ticket": {
"id": 6001,
"title": "Example ticket",
"active": true
},
"ti_event": {
"id": 6201,
"title": "Example event",
"timezone": "UTC",
"start_date": "2026-11-07 18:00:00",
"end_date": "2026-11-07 23:00:00"
},
"resource": {
"id": 2001,
"title": "Example publication",
"key": "EXAMPLE_PUBLICATION_KEY",
"host": "example.com",
"active": true
}
}
]
}
Assume the request happens before event end. Even an event that has not started can pass this check. The result does not confirm selling-window availability, unused status or admission.
No assigned-pass summaries are returned
HTTP 200 response:
{
"items": []
}
An empty list can mean no matches, an unknown account, active/end-date filtering, invalid timezone data or another caught query failure. It does not establish that the account owns no tickets.
Recovery
| HTTP status | API code / response shape | Cause | Next action |
|---|---|---|---|
| 200 | items [] | No selected assigned-active rows, event-end filtering or a caught error. | Check assignment, intended publication and option value. Ask the integration operator to inspect unexpected emptiness, including stored event timezone. |
| Varies / no guaranteed JSON | Other PHP/transport failure | Failure response formats can vary. | Retain any request reference and ask the integration operator to inspect the failure. |
See shared errors. Display the assigned pass with event/publication context. Use a separate admission decision or payment record for those tasks.
Select memberships ending on one calculated date
GET /api/v1/admin/resources/{key}/memberships/before-end-subscription
Find memberships whose expiration calendar date equals now plus interval. Despite the route name, this selects one date, not every membership expiring within the interval.
Before you call
Use an eligible service-api-key with resource, or root. Ordinary Admin roles are not eligible. The example uses the same intended publication key in path and header.
Use the intended publication’s public key in both the path and the resource header, with the existing service credential assigned to that context. The path key selects the report’s publication.
Request
No body is needed. The path uses the public publication key, not a numeric ID or secret.
| Query input | Type / requirement | Meaning and constraints |
|---|---|---|
| interval | Required trimmed string | 1–4 digits, one whitespace, then day, days, month, year, week, hours or minute, case-insensitive. Example: 7 days. This is not unrestricted duration syntax; unsupported plurals such as months are rejected. Use a positive interval for a date ahead of now. |
| page | Optional integer; default 1 | Offset is zero unless page is greater than 1. Use positive page values. |
| limit | Optional integer; default 100 | Membership rows per page. Use a positive value; zero/invalid limits do not have a guaranteed clean validation response. |
The server calculates a calendar date in its default timezone, then matches database DATE(expiration). This is not a rolling-hour window or guaranteed reader/publication-timezone calculation. This is a date-only report. Verify account/catalog status, trial and renewal settings, and contact eligibility separately before taking action. Null expirations do not match. Rows sort by membership creation ascending, without a stable tie order.
Response fields
HTTP 200 normally returns top-level pagination fields, rather than nested paginator:
| Field | Meaning / type |
|---|---|
| page | Requested page value. |
| limit | Requested/default page size. |
| total_items | Count of matching membership rows, not distinct readers. Stored count scalar representation can vary. |
| total_pages | Ceiling of total_items / limit. With positive default limit and no matches, 0. |
| has_more | Boolean: total_items exceeds limit multiplied by page. |
| items | Array of the ten-field row shape below, including [] when none selected. |
| Item field | Meaning / stored type |
|---|---|
| user_plan_relationship_id | Membership relationship-row ID, distinct from catalog subscription ID. |
| plan_id | Membership’s Plan reference. |
| subscription_id | Membership’s catalog subscription reference. |
| user_id | Associated global account ID; multiple memberships can refer to the same account. |
| plan_title | Current joined Plan title, potentially null. |
| subscription_title | Current joined catalog subscription title, potentially null. |
| autorenew | Stored membership renewal-choice flag, not filtered to false. |
| is_trial | Stored trial marker, not an eligibility decision. |
| subscription_is_allowed_autorenew | Stored catalog renewal permission, not an action performed by this read. |
| subscription_end_date | Stored expiration timestamp whose DATE matches the calculated target date. |
IDs and flags follow stored types. No profile, email, credential, contact eligibility or renewal action is returned. Counts and rows are read separately and can differ during concurrent changes.
Example: Read rows ending seven calendar days ahead
Replace the placeholder in path and header with the same intended key. The service account must already be eligible. With a synthetic server date of October 31, 2026, seven days selects November 7, 2026.
curl "${WALLKIT_API_BASE}/api/v1/admin/resources/EXAMPLE_PUBLICATION_KEY/memberships/before-end-subscription" \
-X GET \
-H "resource: EXAMPLE_PUBLICATION_KEY" \
-H "service-api-key: ${SERVICE_API_KEY}" \
--get \
--data-urlencode 'interval=7 days' \
--data-urlencode 'page=1' \
--data-urlencode 'limit=100'
const url = new URL(`${process.env.WALLKIT_API_BASE}/api/v1/admin/resources/EXAMPLE_PUBLICATION_KEY/memberships/before-end-subscription`);
url.search = new URLSearchParams({"interval": "7 days", "page": "1", "limit": "100"}).toString();
const response = await fetch(url, {
method: "GET",
headers: {"resource": "EXAMPLE_PUBLICATION_KEY", "service-api-key": process.env.SERVICE_API_KEY}
});
console.log(response.status, await response.json());
import os, json
from urllib.request import Request, urlopen
from urllib.error import HTTPError
from urllib.parse import urlencode
url = os.environ["WALLKIT_API_BASE"] + "/api/v1/admin/resources/EXAMPLE_PUBLICATION_KEY/memberships/before-end-subscription"
url += "?" + urlencode({'interval': '7 days', 'page': '1', 'limit': '100'})
request = Request(
url,
headers={"resource": "EXAMPLE_PUBLICATION_KEY", "service-api-key": os.environ["SERVICE_API_KEY"]},
method="GET"
)
try:
with urlopen(request) as response:
print(response.status, json.load(response))
except HTTPError as error:
print(error.code, json.load(error))
HTTP 200 response:
{
"page": 1,
"limit": 100,
"total_items": 1,
"total_pages": 1,
"has_more": false,
"items": [
{
"user_plan_relationship_id": 7001,
"plan_id": 5001,
"subscription_id": 3001,
"user_id": 1002,
"plan_title": "Example Plan",
"subscription_title": "Example subscription",
"autorenew": false,
"is_trial": false,
"subscription_is_allowed_autorenew": true,
"subscription_end_date": "2026-11-07 12:00:00"
}
]
}
This selects November 7, not all expirations from October 31 through November 7. It neither renews memberships nor sends reminders.
An unsupported interval is rejected
HTTP 409 for an unsupported interval such as 7 months:
{
"error": "interval_format",
"error_description": "Interval format not supported",
"req_guid": "example-request"
}
Use an accepted interval form. A valid empty query normally returns items: [], zero totals/pages and has_more: false. A caught non-validation exception can instead return HTTP 200 without those fields, with a nominal [] or diagnostic object. Missing fields are not a confirmed empty report.
Recovery
| HTTP status | API code / response shape | Cause | Next action |
|---|---|---|---|
| 404 | invalid_resource_key | Path key does not resolve a publication. | Check the same known intended public key in path/header and the existing integration context; do not substitute an unrelated publication key. |
| 409 | interval_required | interval is missing or empty. | Supply a supported explicit interval such as 7 days. |
| 409 | interval_format | interval fails the accepted pattern. | Use the exact supported units/form and verify the intended single target date. |
| 200 | Full pagination with items [] / zero totals | No matching stored expiration dates, or no rows on the requested page when totals remain nonzero. | Handle the empty page and inspect pagination; do not infer absence of memberships on other dates. |
| 200 | Result fields absent, nominal [] or diagnostic object | A caught non-validation failure can fall through without data fields. | Treat the report as unavailable and ask the integration operator to inspect it, rather than treating it as zero matches. |
| Varies / no guaranteed JSON | Other PHP/transport failure | Not every bad pagination/query failure is normalized. | Use positive page/limit and retain any request reference for operator investigation. |
See shared errors. Use the required service credential rather than an ordinary Admin token. Use returned IDs and dates in reporting; they do not provide a contact list or confirm notification or access eligibility.