API reference
Keywords
Keywords endpoints of the SemanticsOn REST API.
List keywords
GET/projects/{projectId}/keywordsvolume, cpc and competition are only set when they came from a connected data provider (metricSource: provider) or your own import (metricSource: user_import); otherwise they are null. aiCompetitionEstimate is a qualitative AI judgement, not a measured metric.
Path parameters
projectIdstringrequired
Query parameters
limitintegeroptionalItems per page, 1–100.
1–100 · default 25
cursorstringoptionalPass
nextCursorfrom the previous page to get the next one.at most 200 characters
clusterIdstringoptionalOnly keywords in this cluster (
nonefor unclustered)intentstringoptionalsearchstringoptionalat most 200 characters
curl https://semanticson.com/api/v1/projects/PROJECT_ID/keywords \
-H "Authorization: Bearer $SEMANTICSON_API_KEY"Response · 200 OK
A list object: { "object": "list", "data": [ … ], "hasMore": false, "nextCursor": null }. See pagination.
Errors use the standard error object.
Add or update keywords (batch)
POST/projects/{projectId}/keywordsAdds up to 500 keywords at once. Phrases are stored lower-case with collapsed whitespace; a phrase that already exists in the project is updated with the fields you send (created / updated count both). You may include your own volume, cpc and competition — they are stored with metricSource: user_import (sending all three as null clears them). volume, cpc and competition are only set when they came from a connected data provider (metricSource: provider) or your own import (metricSource: user_import); otherwise they are null. aiCompetitionEstimate is a qualitative AI judgement, not a measured metric.
Accepts an Idempotency-Key header for safe retries.
Path parameters
projectIdstringrequired
Request body
keywordsarray of objectsrequired1–500 items
keywords[].phrasestringrequired1–200 characters
keywords[].intentstringoptionalOne of:
,informational,commercial,transactional,navigationalkeywords[].clusterIdstring or nulloptionalCluster in the same project, or null
1–64 characters
keywords[].mappedUrlstring or nulloptionalURL that targets this keyword
at most 500 characters
keywords[].notesstringoptionalat most 1,000 characters
keywords[].volumeinteger or nulloptionalMonthly search volume from your own data
0–1,000,000,000
keywords[].cpcnumber or nulloptionalCost per click from your own data
0–100,000
keywords[].competitionnumber or nulloptionalCompetition value from your own data (any 0–100 scale, e.g. 0.42 or 42)
0–100
curl -X POST https://semanticson.com/api/v1/projects/PROJECT_ID/keywords \
-H "Authorization: Bearer $SEMANTICSON_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"keywords": [
{
"phrase": "espresso grind size",
"intent": "informational",
"clusterId": "cm1cluster…"
},
{
"phrase": "best espresso grinder",
"intent": "commercial",
"volume": 5400,
"cpc": 1.35,
"competition": 0.62
}
]
}'Response · 201 Created
A JSON object. Objects carry an object type and an id; timestamps are ISO 8601 strings.
Errors use the standard error object.
Get a keyword
GET/keywords/{keywordId}volume, cpc and competition are only set when they came from a connected data provider (metricSource: provider) or your own import (metricSource: user_import); otherwise they are null. aiCompetitionEstimate is a qualitative AI judgement, not a measured metric.
Path parameters
keywordIdstringrequiredThe keyword id
1–64 characters
curl https://semanticson.com/api/v1/keywords/KEYWORD_ID \
-H "Authorization: Bearer $SEMANTICSON_API_KEY"Response · 200 OK
A JSON object. Objects carry an object type and an id; timestamps are ISO 8601 strings.
Errors use the standard error object.
Update a keyword
PATCH/keywords/{keywordId}Send only the fields to change. Sending any of volume, cpc, competition replaces all three with your own values (missing ones become null) and sets metricSource: user_import; sending all three as null clears the metrics. Renaming to a phrase that already exists in the project returns 409.
Accepts an Idempotency-Key header for safe retries.
Path parameters
keywordIdstringrequiredThe keyword id
1–64 characters
Request body
phrasestringoptional1–200 characters
intentstringoptionalOne of:
,informational,commercial,transactional,navigationalclusterIdstring or nulloptionalCluster in the same project, or null
1–64 characters
mappedUrlstring or nulloptionalURL that targets this keyword
at most 500 characters
notesstringoptionalat most 1,000 characters
volumeinteger or nulloptionalMonthly search volume from your own data
0–1,000,000,000
cpcnumber or nulloptionalCost per click from your own data
0–100,000
competitionnumber or nulloptionalCompetition value from your own data (any 0–100 scale, e.g. 0.42 or 42)
0–100
curl -X PATCH https://semanticson.com/api/v1/keywords/KEYWORD_ID \
-H "Authorization: Bearer $SEMANTICSON_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"intent": "commercial",
"clusterId": "cm1cluster…",
"mappedUrl": "https://example.com/grinders",
"volume": 5400
}'Response · 200 OK
A JSON object. Objects carry an object type and an id; timestamps are ISO 8601 strings.
Errors use the standard error object.
Delete a keyword
DELETE/keywords/{keywordId}Accepts an Idempotency-Key header for safe retries.
Path parameters
keywordIdstringrequiredThe keyword id
1–64 characters
curl -X DELETE https://semanticson.com/api/v1/keywords/KEYWORD_ID \
-H "Authorization: Bearer $SEMANTICSON_API_KEY"Response · 204 No Content
Success returns an empty body (204) or a small confirmation object.
Errors use the standard error object.
Delete keywords (batch)
POST/projects/{projectId}/keywords/deleteDeletes up to 1,000 keywords of the project by id. Ids that are not in the project are ignored; deleted is the number actually removed.
Accepts an Idempotency-Key header for safe retries.
Path parameters
projectIdstringrequired
Request body
idsarray of stringsrequired1–1,000 items
curl -X POST https://semanticson.com/api/v1/projects/PROJECT_ID/keywords/delete \
-H "Authorization: Bearer $SEMANTICSON_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"ids": [
"cm1kw1…",
"cm1kw2…"
]
}'Response · 200 OK
A JSON object. Objects carry an object type and an id; timestamps are ISO 8601 strings.
Errors use the standard error object.