> ## Documentation Index
> Fetch the complete documentation index at: https://docs.getlurk.com/llms.txt
> Use this file to discover all available pages before exploring further.

# List what happened and what didn't

> Lists, newest first, receipts, rules that heard an event and did nothing (kept at least 30 days) and changes waiting for a person. Filter by `kind` (`given`, `skipped` or `held`), person, rule, unit or time. A unit filter keeps receipts and held changes. [Activity](/activity#the-feed)



## OpenAPI

````yaml /api-reference/openapi.json get /v1/activity-feed
openapi: 3.1.0
info:
  title: Lurk API
  version: 1.0.0
  description: Events in, rules decide, units change, receipts out.
servers:
  - url: https://api.getlurk.com
security: []
tags:
  - name: events
    description: Send what your users do. Lurk runs your live rules on each event.
    x-group: Events
    x-displayName: Events
  - name: units
    description: What people collect and hold, and their balances.
    x-group: Units
    x-displayName: Units
  - name: rules
    description: What Lurk does when an event comes in. A person takes a rule live.
    x-group: Rules
    x-displayName: Rules
  - name: activity
    description: A receipt for every change, with why it happened.
    x-group: Receipts
    x-displayName: Receipts
  - name: users
    description: The people your events are about.
    x-group: People
    x-displayName: People
  - name: webhook_endpoints
    description: Where Lurk sends signed notices of what changed.
    x-group: Webhooks
    x-displayName: Webhooks
  - name: known_values
    description: The properties of your own events whose values Lurk remembers.
    x-group: Known values
    x-displayName: Known values
  - name: feedback
    description: Tell the Lurk team about a bug, a gap or an idea.
    x-group: Feedback
    x-displayName: Feedback
  - name: annotations
    description: >-
      Short notes on a day of the project, such as a release or a campaign
      start.
    x-group: Annotations
    x-displayName: Annotations
  - name: trusted_issuers
    description: The sign-in providers a project trusts for its app's users.
    x-group: Trusted issuers
    x-displayName: Trusted issuers
  - name: client_events
    description: The events a signed-in device may send, and their caps.
    x-group: Client events
    x-displayName: Client events
  - name: issuer_identities
    description: Which person each sign-in subject is bound to.
    x-group: Issuer identities
    x-displayName: Issuer identities
  - name: proposals
    description: Changes an agent or Lurky asks for and a person approves or declines.
    x-group: Proposals
    x-displayName: Proposals
  - name: holds
    description: Changes a rule parked for a person to give or refuse.
    x-group: Holds
    x-displayName: Holds
  - name: audiences
    description: The groups of people that rules can read.
    x-group: Audiences
    x-displayName: Audiences
  - name: budgets
    description: What each live rule's budgets have given in the window they are in now.
    x-group: Budgets
    x-displayName: Budgets
  - name: templates
    description: Kits that add units and rules to a project in one go.
    x-group: Templates
    x-displayName: Templates
  - name: views
    description: Saved questions about a project, with their answers.
    x-group: Views
    x-displayName: Views
  - name: integrations
    description: Every way events reach Lurk or state leaves it, and the state of each.
    x-group: Integrations
    x-displayName: Integrations
  - name: projects
    description: Where units, rules and events live. An organization can have several.
    x-group: Projects
    x-displayName: Projects
  - name: clocks
    description: A test project's clock, which can be moved to try schedules and expiries.
    x-group: Clocks
    x-displayName: Clocks
paths:
  /v1/activity-feed:
    get:
      tags:
        - activity
      summary: List what happened and what didn't
      description: >-
        Lists, newest first, receipts, rules that heard an event and did nothing
        (kept at least 30 days) and changes waiting for a person. Filter by
        `kind` (`given`, `skipped` or `held`), person, rule, unit or time. A
        unit filter keeps receipts and held changes.
        [Activity](/activity#the-feed)
      operationId: activity.feed
      parameters:
        - schema:
            type: integer
            minimum: 1
            maximum: 200
            default: 50
            description: How many items to return, 1 to 200
          required: false
          description: How many items to return, 1 to 200
          name: limit
          in: query
        - schema:
            type: string
            minLength: 1
            maxLength: 512
            description: >-
              The `next_cursor` of the previous page; leave out for the first
              page
          required: false
          description: The `next_cursor` of the previous page; leave out for the first page
          name: cursor
          in: query
        - schema:
            type: string
            enum:
              - all
              - given
              - skipped
              - held
              - effect
              - mirror
            description: >-
              Only this kind of item: `given` (receipts), `skipped` or `held`.
              `effect` and `mirror` are not available yet. Defaults to `all`
          required: false
          description: >-
            Only this kind of item: `given` (receipts), `skipped` or `held`.
            `effect` and `mirror` are not available yet. Defaults to `all`
          name: kind
          in: query
        - schema:
            type: string
            minLength: 1
            maxLength: 64
            description: A usr_… ID
          required: false
          description: A usr_… ID
          name: user
          in: query
        - schema:
            type: string
            minLength: 1
            maxLength: 100
            description: A rule_… ID or the rule's key
          required: false
          description: A rule_… ID or the rule's key
          name: rule
          in: query
        - schema:
            type: string
            pattern: ^[a-z][a-z0-9_-]{0,63}$
            description: >-
              Receipts and held changes that involve this unit; skips changed
              none
          required: false
          description: Receipts and held changes that involve this unit; skips changed none
          name: unit
          in: query
        - schema:
            type: string
            format: date-time
            description: 'From this time on, this time included: ISO 8601, UTC'
          required: false
          description: 'From this time on, this time included: ISO 8601, UTC'
          name: since
          in: query
        - schema:
            type: string
            format: date-time
            description: 'Up to this time, this time included: ISO 8601, UTC'
          required: false
          description: 'Up to this time, this time included: ISO 8601, UTC'
          name: until
          in: query
        - schema:
            type: string
            description: W3C Trace Context; joins your trace to ours
          required: false
          description: W3C Trace Context; joins your trace to ours
          name: traceparent
          in: header
      responses:
        '200':
          description: List what happened and what didn't
          headers:
            Request-Id:
              schema:
                type: string
                description: Quote this when you contact support
              required: true
              description: Quote this when you contact support
            traceparent:
              schema:
                type: string
                description: W3C Trace Context for this call, in the caller's trace
              required: true
              description: W3C Trace Context for this call, in the caller's trace
            RateLimit:
              schema:
                type: string
                description: The tightest limit now, e.g. `"ingest-key";r=5999;t=42`
              required: true
              description: The tightest limit now, e.g. `"ingest-key";r=5999;t=42`
            RateLimit-Policy:
              schema:
                type: string
                description: Its quota and window, e.g. `"ingest-key";q=6000;w=60`
              required: true
              description: Its quota and window, e.g. `"ingest-key";q=6000;w=60`
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/FeedList'
        '429':
          description: Too many requests. Wait `Retry-After` seconds.
          headers:
            Request-Id:
              schema:
                type: string
                description: Quote this when you contact support
              required: true
              description: Quote this when you contact support
            traceparent:
              schema:
                type: string
                description: W3C Trace Context for this call, in the caller's trace
              required: true
              description: W3C Trace Context for this call, in the caller's trace
            RateLimit:
              schema:
                type: string
                description: The tightest limit now, e.g. `"ingest-key";r=5999;t=42`
              required: true
              description: The tightest limit now, e.g. `"ingest-key";r=5999;t=42`
            RateLimit-Policy:
              schema:
                type: string
                description: Its quota and window, e.g. `"ingest-key";q=6000;w=60`
              required: true
              description: Its quota and window, e.g. `"ingest-key";q=6000;w=60`
            Retry-After:
              schema:
                type: string
                description: Seconds to wait
              required: true
              description: Seconds to wait
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        default:
          description: Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      security:
        - bearerAuth: []
components:
  schemas:
    FeedList:
      type: object
      properties:
        data:
          type: array
          items:
            $ref: '#/components/schemas/FeedItem'
          description: The items on this page
        has_more:
          type: boolean
          description: Whether there are older items after this page
        next_cursor:
          type:
            - string
            - 'null'
          description: Pass it as `cursor` to get the next page; null on the last page
      required:
        - data
        - has_more
        - next_cursor
    Error:
      type: object
      properties:
        error:
          type: object
          properties:
            status:
              type: integer
            code:
              type: string
              enum:
                - invalid_json
                - invalid_key
                - forbidden
                - approval_required
                - not_found
                - idempotency_conflict
                - conflict
                - unblock_clock_reversed
                - insufficient_balance
                - reference_used
                - validation_failed
                - rate_limited
                - internal
                - unavailable
            message:
              type: string
            param:
              type: string
            next_step:
              type: string
              description: >-
                What to do about this kind of error, in one sentence. Always
                sent by current servers
            request_id:
              type: string
            doc_url:
              type: string
              format: uri
          required:
            - status
            - code
            - message
            - request_id
            - doc_url
      required:
        - error
    FeedItem:
      oneOf:
        - $ref: '#/components/schemas/FeedGiven'
        - $ref: '#/components/schemas/FeedSkipped'
        - $ref: '#/components/schemas/FeedHeld'
        - $ref: '#/components/schemas/FeedEffect'
        - $ref: '#/components/schemas/FeedMirror'
      discriminator:
        propertyName: kind
        mapping:
          given: '#/components/schemas/FeedGiven'
          skipped: '#/components/schemas/FeedSkipped'
          held: '#/components/schemas/FeedHeld'
          effect: '#/components/schemas/FeedEffect'
          mirror: '#/components/schemas/FeedMirror'
    FeedGiven:
      type: object
      properties:
        id:
          type: string
          description: The act_… ID
        at:
          type: string
          format: date-time
          description: 'When the change was made: ISO 8601, UTC'
        user:
          type: object
          properties:
            id:
              type: string
              description: The usr_… ID
            external_id:
              type: string
              description: 'The brand''s own identifier for the person: an email, a user ID'
          required:
            - id
            - external_id
          description: The person it happened to
        by:
          type: string
          description: 'Who acted: "rule:<key>" for rules'
        via:
          type: string
          enum:
            - api
            - agent
            - lurky
            - dashboard
            - system
            - chat
            - device
          description: >-
            How the change arrived: `api` (a project key), `agent`, `lurky`,
            `dashboard` (a signed-in member) or `system` (Lurk itself, such as
            an expiry or a schedule), `device` (a person signing in, where
            device sign-in is switched on) or `chat` (not available yet)
        agent:
          type:
            - string
            - 'null'
          description: The agent's name when an agent or Lurky acted
        event:
          type:
            - object
            - 'null'
          properties:
            id:
              type: string
              description: The evt_… ID
            name:
              type: string
              maxLength: 100
              pattern: ^[a-z][a-z0-9_]*(\.[a-z][a-z0-9_]*)+$
              description: >-
                An event's name: lowercase words joined by dots, thing first,
                such as `checkin.scanned`
          required:
            - id
            - name
          description: >-
            The event it came from; null for a change made by hand or by a
            schedule
        lines:
          type: array
          items:
            $ref: '#/components/schemas/ActivityLine'
          description: One for each unit the receipt changed
        reverses:
          type:
            - string
            - 'null'
          description: The receipt this one undoes
        reversed_by:
          type:
            - string
            - 'null'
          description: The receipt that undid this one
        note:
          type:
            - string
            - 'null'
          description: >-
            What the person wrote when they gave by hand, or the reason on a
            spend; null otherwise
        cause:
          type:
            - string
            - 'null'
          enum:
            - spend
            - use
            - send
            - receive
            - null
          description: >-
            `spend` for value a brand took in exchange for something, `use` for
            something a person redeemed, `send` and `receive` for the two sides
            of one unit moving between people; null for a rule's change, a give
            or an undo
        reference:
          type:
            - string
            - 'null'
          description: The brand's own redemption or order ID on a spend; null otherwise
        transfer:
          type:
            - string
            - 'null'
          description: >-
            On the two receipts of one `units.send`: the same ID on both, the
            sender's receipt ID. Null otherwise
        kind:
          type: string
          enum:
            - given
          description: 'Always `given`: a receipt'
      required:
        - id
        - at
        - user
        - by
        - via
        - agent
        - event
        - lines
        - reverses
        - reversed_by
        - note
        - cause
        - reference
        - transfer
        - kind
    FeedSkipped:
      type: object
      properties:
        kind:
          type: string
          enum:
            - skipped
          description: 'Always `skipped`: a rule heard an event and did nothing'
        id:
          type: string
          pattern: ^skip_[0-7][0-9a-hjkmnp-tv-z]{25}$
          description: A skip ID, starting with `skip_`.
        at:
          type: string
          format: date-time
          description: When the rule heard the event
        user:
          type: object
          properties:
            id:
              type: string
              description: The usr_… ID
            external_id:
              type: string
              description: The brand's own identifier for the person
          required:
            - id
            - external_id
          description: The person it happened to
        by:
          type: string
          description: 'The rule: "rule:<key>"'
        rule:
          type: object
          properties:
            id:
              type: string
              description: The rule_… ID
            key:
              type: string
              description: The rule's key
            name:
              type: string
              description: The rule's name
          required:
            - id
            - key
            - name
          description: The rule that acted
        event:
          type:
            - object
            - 'null'
          properties:
            id:
              type: string
              description: The evt_… ID
            name:
              type: string
              maxLength: 100
              pattern: ^[a-z][a-z0-9_]*(\.[a-z][a-z0-9_]*)+$
              description: >-
                An event's name: lowercase words joined by dots, thing first,
                such as `checkin.scanned`
          required:
            - id
            - name
          description: The event it came from
        reason:
          type: string
          enum:
            - condition_failed
            - condition_unknown
            - limit_reached
            - insufficient_balance
            - unit_setting
            - hold_refused
            - budget_reached
            - supply_gone
          description: >-
            condition_unknown: the holding could not be confirmed, so the rule
            does not fire and is not retried. unit_setting: a unit's own setting
            stopped it (it cannot go up or down, or the change would pass its
            cap). hold_refused: a person refused the change a rule had held.
            budget_reached: the rule has given all its budget for this window.
            supply_gone: a unit with a limited supply has none left for the
            change
        check:
          type: string
          description: 'The check that stopped it: limit, budget, audience, unit…'
      required:
        - kind
        - id
        - at
        - user
        - by
        - rule
        - event
        - reason
        - check
    FeedHeld:
      type: object
      properties:
        kind:
          type: string
          enum:
            - held
          description: 'Always `held`: a change waiting for a person'
        id:
          type: string
          pattern: ^hold_[0-7][0-9a-hjkmnp-tv-z]{25}$
          description: A hold ID, starting with `hold_`.
        at:
          type: string
          format: date-time
          description: When it was held
        user:
          type: object
          properties:
            id:
              type: string
              description: The usr_… ID
            external_id:
              type: string
              description: The brand's own identifier for the person
          required:
            - id
            - external_id
          description: The person it happened to
        by:
          type: string
          description: 'The rule: "rule:<key>"'
        rule:
          type: object
          properties:
            id:
              type: string
              description: The rule_… ID
            key:
              type: string
              description: The rule's key
            name:
              type: string
              description: The rule's name
          required:
            - id
            - key
            - name
          description: The rule that acted
        event:
          type: object
          properties:
            id:
              type: string
              description: The evt_… ID
            name:
              type: string
              maxLength: 100
              pattern: ^[a-z][a-z0-9_]*(\.[a-z][a-z0-9_]*)+$
              description: >-
                An event's name: lowercase words joined by dots, thing first,
                such as `checkin.scanned`
          required:
            - id
            - name
          description: The event it came from
        changes:
          type: array
          items:
            type: object
            properties:
              unit:
                type: string
                pattern: ^[a-z][a-z0-9_-]{0,63}$
                description: The key of the unit that would change
              change:
                type: integer
                description: Positive for giving, negative for taking
            required:
              - unit
              - change
          description: What would change once a person gives it
        reason:
          type: string
          description: 'Why it waits: 900 beans is over 500, so a person decides'
      required:
        - kind
        - id
        - at
        - user
        - by
        - rule
        - event
        - changes
        - reason
    FeedEffect:
      type: object
      properties:
        kind:
          type: string
          enum:
            - effect
          description: >-
            Not available yet. Always `effect`: what a rule did in a chat
            platform
        id:
          type: string
          pattern: ^eff_[0-7][0-9a-hjkmnp-tv-z]{25}$
          description: The effect's ID; for a digest, its first firing's
        at:
          type: string
          format: date-time
          description: When the first firing in it happened
        user:
          type:
            - object
            - 'null'
          properties:
            id:
              type: string
              description: The usr_… ID
            external_id:
              type: string
              description: The brand's own identifier for the person
          required:
            - id
            - external_id
          description: >-
            The person it is about, for a message; null for a post (a digest has
            many people)
        by:
          type: string
          description: 'The rule: "rule:<key>"'
        rule:
          type: object
          properties:
            id:
              type: string
              description: The rule_… ID
            key:
              type: string
              description: The rule's key
            name:
              type: string
              description: The rule's name
          required:
            - id
            - key
            - name
          description: The rule that acted
        event:
          type:
            - object
            - 'null'
          properties:
            id:
              type: string
              description: The evt_… ID
            name:
              type: string
              maxLength: 100
              pattern: ^[a-z][a-z0-9_]*(\.[a-z][a-z0-9_]*)+$
              description: >-
                An event's name: lowercase words joined by dots, thing first,
                such as `checkin.scanned`
          required:
            - id
            - name
          description: The event of the first firing; null for a schedule
        effect:
          type: string
          enum:
            - post
            - dm
          description: >-
            `post`: one message in a channel for everything the rule fired in a
            window. `dm`: a message to one person
        status:
          type: string
          enum:
            - pending
            - held
            - sent
            - failed
            - skipped
          description: >-
            pending: waiting for its window to close or its turn. held: waits
            for a person to give the hold. sent. failed: Lurky could not do it
            (see `detail`). skipped: never done on purpose (see `detail`)
        firings:
          type: integer
          minimum: 1
          description: How many times the rule fired into this one post (the `{count}`)
        summary:
          type: string
          description: 'In words: "Posted in #general by Daily thanks"'
        detail:
          type:
            - string
            - 'null'
          description: >-
            Why it failed or was skipped, in a sentence a person can act on;
            null otherwise. A post or message cannot be recalled once sent
      required:
        - kind
        - id
        - at
        - user
        - by
        - rule
        - event
        - effect
        - status
        - firings
        - summary
        - detail
    FeedMirror:
      type: object
      properties:
        kind:
          type: string
          enum:
            - mirror
          description: >-
            Not available yet. Always `mirror`: a role, group or tag Lurky gave
            or took back
        id:
          type: string
          pattern: ^mch_[0-7][0-9a-hjkmnp-tv-z]{25}$
          description: The change's ID
        at:
          type: string
          format: date-time
          description: When the change was made
        user:
          type: object
          properties:
            id:
              type: string
              description: The usr_… ID
            external_id:
              type: string
              description: The brand's own identifier for the person
          required:
            - id
            - external_id
          description: The person who got it or lost it
        by:
          type: string
          description: 'The mirror: "mirror:<mir_… ID>"'
        mirror:
          type: object
          properties:
            id:
              type: string
              pattern: ^mir_[0-7][0-9a-hjkmnp-tv-z]{25}$
              description: A mirror ID, starting with `mir_`.
            label:
              type: string
              description: The mirror's name, such as the role it keeps true
          required:
            - id
            - label
          description: The mirror that made the change
        connector:
          type: string
          description: 'The platform: discord, slack or telegram'
        action:
          type: string
          enum:
            - given
            - taken
          description: 'given: Lurky gave it. taken: Lurky took it back'
        summary:
          type: string
          description: 'In words: "Role Regular removed on Discord"'
        detail:
          type:
            - string
            - 'null'
          description: 'Why: what the person holds, against the threshold'
      required:
        - kind
        - id
        - at
        - user
        - by
        - mirror
        - connector
        - action
        - summary
        - detail
    ActivityLine:
      type: object
      properties:
        unit:
          type: string
          pattern: ^[a-z][a-z0-9_-]{0,63}$
          description: The key of the unit that changed
        change:
          type: integer
          description: Positive for giving, negative for taking
        balance:
          type: integer
          description: The person's balance of this unit after the change
        rule:
          type:
            - string
            - 'null'
          description: The key of the rule that made this change
      required:
        - unit
        - change
        - balance
        - rule
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        A project key (Developers → API keys). Keep it on your server, not in an
        app.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.