> For the complete documentation index, see [llms.txt](https://nviasoft.gitbook.io/nviasoft-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://nviasoft.gitbook.io/nviasoft-docs/api-reference/item-parsing/getruntimestate.md).

# GetRuntimeState

### int GetRuntimeState()

EZGemPlus에 설정된 RuntimeState (Liscense 인증여부) 값을 반환.

{% hint style="danger" %}
Liscense Check는 20분 간격으로 3회 진행하며 이후 미 인식시 프로그램이 STOP됩니다. 라이선스 여부는 GEM 구동시 GEM LOG에 기록됩니다.&#x20;

PRODUCT TYPE : EVALUATION = 라이선스 키 없음

PRODUCT TYPE : PURCHASED = 라이선스 키 정상 삽입되어있음
{% endhint %}

Return Value

<table data-header-hidden><thead><tr><th width="135" valign="top"></th><th valign="top"></th></tr></thead><tbody><tr><td valign="top">Value</td><td valign="top">Description</td></tr><tr><td valign="top">0</td><td valign="top">비구매 버전 (Product Type : Evaluation)</td></tr><tr><td valign="top">1</td><td valign="top">구매 버전 (Product Type : Purchased)</td></tr></tbody></table>

```csharp
// 현재 실행 중인 모듈의 라이선스 상태 확인
int runtimeState = m_gem.GetRuntimeState();

if (runtimeState == 1)
{
    // 정식 버전 로직
    Console.WriteLine("System is running on a [Purchased] license.");
}
else
{
    // 평가판 버전 로직 (기능 제한 알림 등)
    Console.WriteLine("System is running on an [Evaluation] license.");
}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://nviasoft.gitbook.io/nviasoft-docs/api-reference/item-parsing/getruntimestate.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
