API

Description of the OC-post API endpoint.

Article URLs

GET https://site.example.com/api/oc-post/

This endpoint allows you to get article URL for any article in Open Content (OC). Or you can also do it the other way around and get the article UUID for any existing URL.

Query Parameters

NameTypeDescription

uuid

string

The API will give you the URL back for the requested Article UUID. As long as the article is available in Open Content, published and thereby accessible to Naviga Web and the current site, an article that hasn't been added to WordPress yet will be fetched and created in WordPress before it is handled further.

url

string

You can also do a reverse check by requesting an article by its URL. If the article is not accessible or still has not been triggered for URL generation on the site you will get a 404. You may get 404 for new articles the first minute(s) until URL caching has been triggered.

redirect

string

This is an (Optional) parameter which offers a way to actually be redirected to the requested article. On errors during a redirect request, you will instead be redirected to the site´s "404 page".

{
    uuid: "f1c4e0d8-f32c-5e23-8136-bd9ff8ed63fc",
    url: "https://site.example.com/your-example-article"
}

Last updated