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

# Get Catalog

> Catalog of offered achievements + the caller's own earn state, ONE query.

Secret achievements are excluded unless the caller has earned them
(revoked included — the caller has already seen the badge).



## OpenAPI

````yaml /openapi/mio-openapi.json get /api/v1/hubs/{hub_id}/achievements
openapi: 3.1.0
info:
  description: >-
    Production API reference for Membership.io. Use the authored guides for
    workflows and the generated endpoint pages for exact parameters and schemas.
  title: Membership.io API
  version: 0.1.0
servers:
  - description: Production
    url: https://api.member.dev
security:
  - bearerAuth: []
paths:
  /api/v1/hubs/{hub_id}/achievements:
    get:
      tags:
        - achievements
      summary: Get Catalog
      description: >-
        Catalog of offered achievements + the caller's own earn state, ONE
        query.


        Secret achievements are excluded unless the caller has earned them

        (revoked included — the caller has already seen the badge).
      operationId: achievements.get_achievements_get_hubs_by_hub_id_achievements
      parameters:
        - in: path
          name: hub_id
          required: true
          schema:
            title: Hub Id
            type: string
        - in: query
          name: page[after]
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Page[After]
        - in: query
          name: page[size]
          required: false
          schema:
            default: 20
            maximum: 100
            minimum: 1
            title: Page[Size]
            type: integer
        - in: query
          name: filter[id]
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Filter[Id]
      responses:
        '200':
          content:
            application/vnd.api+json:
              schema:
                $ref: >-
                  #/components/schemas/JsonApiListResponse_AchievementCatalogAttributes_
          description: Successful Response
        '422':
          content:
            application/vnd.api+json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
          description: Validation Error
      security:
        - HTTPBearer: []
components:
  schemas:
    JsonApiListResponse_AchievementCatalogAttributes_:
      properties:
        data:
          items:
            $ref: '#/components/schemas/JsonApiResource_AchievementCatalogAttributes_'
          title: Data
          type: array
        included:
          anyOf:
            - items: {}
              type: array
            - type: 'null'
          title: Included
        links:
          anyOf:
            - $ref: '#/components/schemas/JsonApiPaginationLinks'
            - type: 'null'
        meta:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Meta
      required:
        - data
      title: JsonApiListResponse[AchievementCatalogAttributes]
      type: object
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          title: Detail
          type: array
      title: HTTPValidationError
      type: object
    JsonApiResource_AchievementCatalogAttributes_:
      properties:
        attributes:
          $ref: '#/components/schemas/AchievementCatalogAttributes'
        id:
          title: Id
          type: string
        links:
          anyOf:
            - $ref: '#/components/schemas/JsonApiLinks'
            - type: 'null'
        meta:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Meta
        relationships:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Relationships
        type:
          title: Type
          type: string
      required:
        - id
        - type
        - attributes
      title: JsonApiResource[AchievementCatalogAttributes]
      type: object
    JsonApiPaginationLinks:
      properties:
        next:
          anyOf:
            - type: string
            - type: 'null'
          title: Next
        self:
          anyOf:
            - type: string
            - type: 'null'
          title: Self
      title: JsonApiPaginationLinks
      type: object
    ValidationError:
      properties:
        ctx:
          title: Context
          type: object
        input:
          title: Input
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          title: Location
          type: array
        msg:
          title: Message
          type: string
        type:
          title: Error Type
          type: string
      required:
        - loc
        - msg
        - type
      title: ValidationError
      type: object
    AchievementCatalogAttributes:
      description: |-
        Definition attributes plus the viewer's own (nullable) earn state.

        Used by member-facing catalog reads: earned_at/points_awarded/revoked_at
        are None when the viewer has not earned this achievement.
      properties:
        appearance:
          anyOf:
            - $ref: '#/components/schemas/AchievementAppearance'
            - type: 'null'
        award_mode:
          title: Award Mode
          type: string
        category:
          anyOf:
            - type: string
            - type: 'null'
          title: Category
        created_at:
          format: date-time
          title: Created At
          type: string
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
        earned_at:
          anyOf:
            - format: date-time
              type: string
            - type: 'null'
          title: Earned At
        email_notification_enabled:
          title: Email Notification Enabled
          type: boolean
        is_active:
          title: Is Active
          type: boolean
        is_secret:
          title: Is Secret
          type: boolean
        points:
          title: Points
          type: integer
        points_awarded:
          anyOf:
            - type: integer
            - type: 'null'
          title: Points Awarded
        revoked_at:
          anyOf:
            - format: date-time
              type: string
            - type: 'null'
          title: Revoked At
        title:
          title: Title
          type: string
        updated_at:
          format: date-time
          title: Updated At
          type: string
      required:
        - title
        - award_mode
        - points
        - is_secret
        - is_active
        - email_notification_enabled
        - created_at
        - updated_at
      title: AchievementCatalogAttributes
      type: object
    JsonApiLinks:
      properties:
        self:
          anyOf:
            - type: string
            - type: 'null'
          title: Self
      title: JsonApiLinks
      type: object
    AchievementAppearance:
      additionalProperties: false
      description: Validated `appearance` JSONB payload for an achievement definition.
      properties:
        color:
          default: '#5581f4'
          title: Color
          type: string
        content_color:
          default: '#ffffff'
          title: Content Color
          type: string
        emoji:
          anyOf:
            - maxLength: 16
              type: string
            - type: 'null'
          title: Emoji
        fill_color:
          anyOf:
            - type: string
            - type: 'null'
          title: Fill Color
        icon:
          anyOf:
            - type: string
            - type: 'null'
          title: Icon
        image_src:
          anyOf:
            - maxLength: 2048
              type: string
            - type: 'null'
          title: Image Src
        shape:
          default: hexagon
          title: Shape
          type: string
        text:
          anyOf:
            - maxLength: 8
              type: string
            - type: 'null'
          title: Text
      title: AchievementAppearance
      type: object
  securitySchemes:
    bearerAuth:
      bearerFormat: JWT or mio_sk API key
      description: >-
        Send platform JWTs, contact JWTs, or team API keys as `Authorization:
        Bearer <token>`.
      scheme: bearer
      type: http
    HTTPBearer:
      scheme: bearer
      type: http

````