For the complete documentation index, see llms.txt. This page is also available as Markdown.

Store API

PremsBlog is fully headless-capable: anything you see in the shop is also available through the Shopware Store API. This page is the technical reference for your developer or integrator.

General

All endpoints live under the standard path /store-api/prems-blog/... and follow the exact Shopware conventions. Responses are returned as JSON.

Required headers

Header
Required
Meaning

sw-access-key

yes

Sales-channel access key (found in the administration under Sales channels → Detail).

sw-context-token

only for POST reviews

Customer context token of an active session.

sw-language-id

no

UUID of the desired language; without it the sales channel's default language is used. Translated fields automatically fall back to the default language when no translation exists.

Content-Type: application/json

for POST

for request bodies.

Sales-channel activation

If the plugin is not active in a sales channel (see Plugin configuration), every endpoint responds with 404 Not Found. Visibility stays consistent: whatever the shop hides, the API hides as well.


Article list

GET /store-api/prems-blog/articles

Login required: No

Returns a paginated list of active articles. Honours the activity window (activeFrom / activeTo) and the plan limits of the active licence.

Query parameters

Parameter
Type
Default
Meaning

page

int

1

Page number (1-based).

limit

int

12

Articles per page. Clamped to the plan limit.

category

string

One or several category IDs, separated by `

tag

string

One or several tag IDs, separated by `

author

string

One or several author IDs, separated by `

sort

string

newest

Sort: newest, oldest, title-asc, title-desc.

Example response


Article detail

Login required: No

Returns a single article including author, categories, tags, previewMedia and all approved reviews. The translated content field carries the complete CMS layout for your app to hydrate.

Missing or inactive articles

  • 404 Not Found — the article doesn't exist, isn't active, falls outside its visibility window, or isn't assigned to the sales channel of the active access key.


Authors

List

Login required: No

Returns a list of active authors.

Query parameters

Parameter
Type
Default
Meaning

letter

string

Optional A–Z bucket filter (AZ or # for non-alphabetic last names).

page

int

1

Page number.

limit

int

25

Authors per page.

Detail

Login required: No

Returns the author including media (profile picture) and their active articles.


Categories

Login required: No

Returns the blog category including its active articles within the activity window. Supports page, limit and sort like the article list.


Tags

Login required: No

Same shape as categories — tag including active articles.


Submit a review (premium)

Login required: Yes (sw-context-token of a logged-in customer)

Request body

Behaviour

  • points is required (1–5). title and content are optional.

  • Successful responses contain the newly created review with status pending. The review only becomes public after you approve it in the administration (see Reviews).

Errors

  • 400 Bad Request — validation failed (e.g. points outside 1–5).

  • 401 Unauthorized — no valid customer context token in the header.

  • 404 Not Found — article doesn't exist or isn't active.


cURL examples

OpenAPI schema

A complete endpoint specification including schema and response structures is exposed by the standard Shopware endpoint:

The blog routes appear there under the prefix prems-blog.

Last updated

Was this helpful?