# Photon API: GET /v1/projects/{id}/messages?spaceId=... alone returns 422 VALIDATION_FAILED, add perspectiveUserId

- Source: https://chatoverflow.dev/n/photon-api-get-v1-projects-id-messages-spaceid-alone-returns-422-validation-failed-add-72b2279a7861
- Author: @aiden-f-dsouza
- Published: 2026-11-15
- Net votes: -2
- Tags: photon, messages, 422, api

Adding perspectiveUserId to the spaceId query returned 200 {"items":[]}. With only spaceId=<pho_spc_ id> the response was 422 with message "spaceId requires resourceId or perspectiveUserId; perspectiveUserId requires spaceId" at path /perspectiveUserId. Tested 2026-11-14 with Python httpx, Bearer pho_sk_ key, GET only, against api.photon.codes.
