focus_sets
The plans you were focusing on for a period of time.
- GET
/v1/focus_setsList focus sets - GET
/v1/focus_sets/currentGet the current focus set - GET
/v1/focus_sets/{id}Get a focus set
A focus set is the lineup of plans in use for a period: one primary plan and up to two secondary plans.
The focus set object
| Field | Type | Description |
|---|---|---|
object | string | Always "focus_set". |
id | string | Unique id of the focus set. |
primary_plan_id | string or null | The main plan to work on. Null when none was chosen. |
secondary_plan_ids | array of strings | Other plans in the set, in order. Empty when there are none. |
source_report_id | string or null | The report the focus set came from, when any. |
effective_from | string (timestamp) | When the focus set started. |
effective_until | string (timestamp) or null | When it was replaced. Null for the current set. |
is_current | boolean | True for the focus set in use now. |
created_at | string (timestamp) | When the focus set was created. |
Example focus set:
{
"object": "focus_set",
"id": "bc389c05-89d8-4afb-bd9d-f3979b56236e",
"primary_plan_id": "245f4a1a-cbd7-4444-9d09-4752871cfeb6",
"secondary_plan_ids": [
"f7a9731f-f737-4e63-affb-db411b42bc0a"
],
"source_report_id": "03d09dc8-617f-45e0-92fd-a76822838da0",
"effective_from": "2026-05-17T21:14:40.000Z",
"effective_until": null,
"is_current": true,
"created_at": "2026-05-17T21:14:40.000Z"
}Endpoints
Responses carry Request-Id, RateLimit-Limit, RateLimit-Remaining, RateLimit-Reset, and a 429 adds Retry-After. See Headers.
List focus sets
Your focus sets, newest first: ordered by effective_from descending, then id descending. Needs a key with the plans:read scope.
/v1/focus_setsA personal API key (nj_live_...), sent as a bearer token. Create one on the Developer page at https://newjune.co/golf/developer. The scopes listed on each operation are the key scopes it needs.
In: header
Scope: plans:read
Query Parameters
How many items to return, 1 to 100. Defaults to 25.
251 <= value <= 100The next_cursor value from the previous page, passed back unchanged with the same filters.
Response Body
curl "https://data.newjune.co/v1/focus_sets" \
-H "Authorization: Bearer $NEW_JUNE_API_KEY"{
"object": "list",
"data": [
{
"object": "focus_set",
"id": "bc389c05-89d8-4afb-bd9d-f3979b56236e",
"primary_plan_id": "245f4a1a-cbd7-4444-9d09-4752871cfeb6",
"secondary_plan_ids": [
"f7a9731f-f737-4e63-affb-db411b42bc0a"
],
"source_report_id": "03d09dc8-617f-45e0-92fd-a76822838da0",
"effective_from": "2026-05-17T21:14:40.000Z",
"effective_until": null,
"is_current": true,
"created_at": "2026-05-17T21:14:40.000Z"
}
],
"has_more": true,
"next_cursor": "eyJ2IjoxLCJrIjpbIjIwMjYtMDUtMTdUMjE6MTQ6NDAuMDAwMDAwWiIsImJjMzg5YzA1LTg5ZDgtNGFmYi1iZDlkLWYzOTc5YjU2MjM2ZSJdfQ"
}{
"error": {
"type": "invalid_request_error",
"code": "invalid_cursor",
"message": "The cursor is not valid. Use the next_cursor value from a previous response.",
"param": "cursor",
"request_id": "req_5f0c6e2a9b1d4c7e8f3a2b10",
"doc_url": "https://developers.newjune.co/errors#invalid_cursor"
}
}{
"error": {
"type": "authentication_error",
"code": "api_key_expired",
"message": "This API key has expired. Create a new key on the Developer page at newjune.co/golf/developer.",
"param": null,
"request_id": "req_5f0c6e2a9b1d4c7e8f3a2b10",
"doc_url": "https://developers.newjune.co/errors#api_key_expired"
}
}{
"error": {
"type": "permission_error",
"code": "account_suspended",
"message": "API access is suspended for this account.",
"param": null,
"request_id": "req_5f0c6e2a9b1d4c7e8f3a2b10",
"doc_url": "https://developers.newjune.co/errors#account_suspended"
}
}{
"error": {
"type": "rate_limit_error",
"code": "daily_limit_exceeded",
"message": "This account has reached its daily request limit. It resets at midnight UTC.",
"param": null,
"request_id": "req_5f0c6e2a9b1d4c7e8f3a2b10",
"doc_url": "https://developers.newjune.co/errors#daily_limit_exceeded"
}
}{
"error": {
"type": "api_error",
"code": "internal_error",
"message": "Something went wrong on our side. Try again later.",
"param": null,
"request_id": "req_5f0c6e2a9b1d4c7e8f3a2b10",
"doc_url": "https://developers.newjune.co/errors#internal_error"
}
}{
"error": {
"type": "api_error",
"code": "service_unavailable",
"message": "The API is temporarily unavailable. Try again later.",
"param": null,
"request_id": "req_5f0c6e2a9b1d4c7e8f3a2b10",
"doc_url": "https://developers.newjune.co/errors#service_unavailable"
}
}Get the current focus set
The focus set in use now. Returns 404 with code no_current_focus_set when there is none. Needs a key with the plans:read scope.
/v1/focus_sets/currentA personal API key (nj_live_...), sent as a bearer token. Create one on the Developer page at https://newjune.co/golf/developer. The scopes listed on each operation are the key scopes it needs.
In: header
Scope: plans:read
Response Body
curl "https://data.newjune.co/v1/focus_sets/current" \
-H "Authorization: Bearer $NEW_JUNE_API_KEY"{
"object": "focus_set",
"id": "bc389c05-89d8-4afb-bd9d-f3979b56236e",
"primary_plan_id": "245f4a1a-cbd7-4444-9d09-4752871cfeb6",
"secondary_plan_ids": [
"f7a9731f-f737-4e63-affb-db411b42bc0a"
],
"source_report_id": "03d09dc8-617f-45e0-92fd-a76822838da0",
"effective_from": "2026-05-17T21:14:40.000Z",
"effective_until": null,
"is_current": true,
"created_at": "2026-05-17T21:14:40.000Z"
}{
"error": {
"type": "authentication_error",
"code": "api_key_expired",
"message": "This API key has expired. Create a new key on the Developer page at newjune.co/golf/developer.",
"param": null,
"request_id": "req_5f0c6e2a9b1d4c7e8f3a2b10",
"doc_url": "https://developers.newjune.co/errors#api_key_expired"
}
}{
"error": {
"type": "permission_error",
"code": "account_suspended",
"message": "API access is suspended for this account.",
"param": null,
"request_id": "req_5f0c6e2a9b1d4c7e8f3a2b10",
"doc_url": "https://developers.newjune.co/errors#account_suspended"
}
}{
"error": {
"type": "not_found_error",
"code": "no_current_focus_set",
"message": "There is no current focus set for this account.",
"param": null,
"request_id": "req_5f0c6e2a9b1d4c7e8f3a2b10",
"doc_url": "https://developers.newjune.co/errors#no_current_focus_set"
}
}{
"error": {
"type": "rate_limit_error",
"code": "daily_limit_exceeded",
"message": "This account has reached its daily request limit. It resets at midnight UTC.",
"param": null,
"request_id": "req_5f0c6e2a9b1d4c7e8f3a2b10",
"doc_url": "https://developers.newjune.co/errors#daily_limit_exceeded"
}
}{
"error": {
"type": "api_error",
"code": "internal_error",
"message": "Something went wrong on our side. Try again later.",
"param": null,
"request_id": "req_5f0c6e2a9b1d4c7e8f3a2b10",
"doc_url": "https://developers.newjune.co/errors#internal_error"
}
}{
"error": {
"type": "api_error",
"code": "service_unavailable",
"message": "The API is temporarily unavailable. Try again later.",
"param": null,
"request_id": "req_5f0c6e2a9b1d4c7e8f3a2b10",
"doc_url": "https://developers.newjune.co/errors#service_unavailable"
}
}Get a focus set
One focus set by id. Needs a key with the plans:read scope.
/v1/focus_sets/{id}A personal API key (nj_live_...), sent as a bearer token. Create one on the Developer page at https://newjune.co/golf/developer. The scopes listed on each operation are the key scopes it needs.
In: header
Scope: plans:read
Path Parameters
The focus set's id.
Response Body
curl "https://data.newjune.co/v1/focus_sets/bc389c05-89d8-4afb-bd9d-f3979b56236e" \
-H "Authorization: Bearer $NEW_JUNE_API_KEY"{
"object": "focus_set",
"id": "bc389c05-89d8-4afb-bd9d-f3979b56236e",
"primary_plan_id": "245f4a1a-cbd7-4444-9d09-4752871cfeb6",
"secondary_plan_ids": [
"f7a9731f-f737-4e63-affb-db411b42bc0a"
],
"source_report_id": "03d09dc8-617f-45e0-92fd-a76822838da0",
"effective_from": "2026-05-17T21:14:40.000Z",
"effective_until": null,
"is_current": true,
"created_at": "2026-05-17T21:14:40.000Z"
}{
"error": {
"type": "authentication_error",
"code": "api_key_expired",
"message": "This API key has expired. Create a new key on the Developer page at newjune.co/golf/developer.",
"param": null,
"request_id": "req_5f0c6e2a9b1d4c7e8f3a2b10",
"doc_url": "https://developers.newjune.co/errors#api_key_expired"
}
}{
"error": {
"type": "permission_error",
"code": "account_suspended",
"message": "API access is suspended for this account.",
"param": null,
"request_id": "req_5f0c6e2a9b1d4c7e8f3a2b10",
"doc_url": "https://developers.newjune.co/errors#account_suspended"
}
}{
"error": {
"type": "not_found_error",
"code": "resource_not_found",
"message": "No such focus set.",
"param": null,
"request_id": "req_5f0c6e2a9b1d4c7e8f3a2b10",
"doc_url": "https://developers.newjune.co/errors#resource_not_found"
}
}{
"error": {
"type": "rate_limit_error",
"code": "daily_limit_exceeded",
"message": "This account has reached its daily request limit. It resets at midnight UTC.",
"param": null,
"request_id": "req_5f0c6e2a9b1d4c7e8f3a2b10",
"doc_url": "https://developers.newjune.co/errors#daily_limit_exceeded"
}
}{
"error": {
"type": "api_error",
"code": "internal_error",
"message": "Something went wrong on our side. Try again later.",
"param": null,
"request_id": "req_5f0c6e2a9b1d4c7e8f3a2b10",
"doc_url": "https://developers.newjune.co/errors#internal_error"
}
}{
"error": {
"type": "api_error",
"code": "service_unavailable",
"message": "The API is temporarily unavailable. Try again later.",
"param": null,
"request_id": "req_5f0c6e2a9b1d4c7e8f3a2b10",
"doc_url": "https://developers.newjune.co/errors#service_unavailable"
}
}