How to implement the increase of document views (`views`) or update of other fields through API?

Calendar 👁️ 70

When you are running a website, you often need to manage content data in fine detail, such as tracking the views of articles, or modifying other properties of documents in specific scenarios.AnQiCMS (AnQiCMS) provides powerful API interfaces, making these operations possible.This article will introduce you in detail on how to use these interfaces to increase the document view count or update other fields.

Understand the API interaction mode of AnqiCMS

In AnQi CMS, the operations on document data are mainly divided into retrieval (read) and writing (creation/modify).For reading data, there are usually dedicated interfaces; while for writing or modifying data, the design of Anqi CMS provides a flexible but attention should be paid to integrity, especially through the "import" function to achieve the overlay update of existing data.

Get the document's

Related articles

The `data.category` field (such as 1 or 3) represents what type of attribute the classification has?

When using Anq CMS for website content management or secondary development, you may notice that in the data returned by the classification or document detail interface, there is a `type` field under `data.category`. This field's value is usually `1` or `3`, what does it represent in terms of classification, and what practical significance does it have for our content organization and website presentation?Understanding this is very critical for more efficient use of Anqi CMS for website content planning and maintenance.In short

2025-11-09

How to get the list of all tags (Tags) associated with the current document details?

In AnQi CMS, tags are important tools for organizing content, enhancing user experience, and optimizing search engine rankings.They can help visitors find relevant content quickly, and also allow website administrators to better manage information.When we browse the details page of a document, we often hope to see a list of all tags associated with the document, which can not only guide users to discover more relevant content, but also enrich the semantic structure of the page.To obtain the tag list associated with a specific document, we usually need to perform two steps: first, determine the unique identifier of the target document

2025-11-09

Is there a recommended word limit or **practice** for the `description` field in the document details?

In the daily use of AnQi CMS, the `description` field is a seemingly insignificant but extremely important part.It is not just a brief summary of the content, but also a bridge of communication between the website content, search engines, and users.A well-written description that can effectively improve the click-through rate of articles in search results and help search engines better understand the content theme.According to the AnQi CMS documentation, when publishing or importing a document (archive), the `description` field has a clear recommendation

2025-11-09

In addition to retrieving the details of a single document, does Anqi CMS provide an interface to obtain the list of documents under a specific category or model?

When building a website with AnQiCMS, we often have such doubts: In addition to being able to accurately obtain the detailed information of a specific document, does the system also provide a function to obtain a list of all documents under a certain category or model at one time?The answer is affirmative. Anqi CMS fully considers the flexibility of content management and display, providing powerful interfaces to meet such needs.To retrieve the document list under a specific category or model, it mainly relies on the `/api/archive/list` interface provided by AnQi CMS

2025-11-09

How to optimize API requests to improve user experience when loading document details on the front-end page?

In website operation, user experience is always a core consideration. When visitors click into a document detail page, they expect a smooth, fast and secure content loading experience.AnQiCMS (AnQiCMS) provides a powerful and flexible API interface, allowing us to carefully design the document loading mechanism of the front-end page, thereby significantly improving user satisfaction.**Understanding the Core: The Power and Details of the `archiveDetail` Interface** When we talk about loading document details, the focus is initially on the `archiveDetail` interface

2025-11-09

If multiple recommended properties exist in the `flag` field (such as 'hc'), what characteristics does the document have simultaneously?

How to make important information stand out in the vast sea of content on a website and be discovered by users first is the focus of every operator.AnQiCMS (AnQiCMS) provides us with a very flexible and powerful tool for managing the display priority and characteristics of content - that is the `flag` field.This little field, yet contains huge potential for content operation.The mystery of the `flag` field: the叠加effect of multiple attributes In Anqi CMS, the `flag` field plays the role of document "recommended attribute" or "characteristic mark".

2025-11-09

Why does the document detail have `price` and `stock` fields, even though the document is not a product type?

When using AnQiCMS to manage website content, many users may notice a phenomenon: even for ordinary articles, news, and other non-product type documents, the returned data structure still contains the `price` (price) and `stock` (inventory quantity) fields when their details are retrieved through the API.This may seem confusing at first glance, but after understanding the design philosophy of AnQiCMS, it will be found that this is exactly the embodiment of its powerful flexibility and scalability.AnQiCMS is designed at the bottom level

2025-11-09

How to use the `url_token` in the `category` object to build the link of the category?

Building clear and accessible links for your website content in Anqi CMS is a key factor in optimizing user experience and search engine rankings.Among them, using the `url_token` in the `category` object to build category links is an efficient and SEO**compliant method.Understand the role of `url_token` in category links `url_token` is a unique identifier provided by Anqi CMS for each category, usually a short, descriptive English word or pinyin

2025-11-09