> For the complete documentation index, see [llms.txt](https://app.developers.karte.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://app.developers.karte.io/ios-sdk-appendix/appendix-ios-version-update.md).

# \[iOS]iOS向けSDKのバージョン管理とnative\_app\_updateイベントについて

### iOS向けのSDKにおけるバージョン管理の概念

KARTE SDKでは、iOSアプリにおいて**version\_nameとversion\_code**という2つのバージョン管理の概念を使用しています。それぞれの役割は以下の通りです。

* `version_name`: ユーザーに表示されるアプリのバージョンを表します。Info.plistファイル内のCFBundleShortVersionStringに指定される値です。通常、アプリのメジャーリリースや新機能の追加に伴って更新され、形式は「1.0.0」や「2.1.3」のようなバージョン番号になります。
* `version_code`: アプリのビルド番号を表します。Info.plistファイル内のCFBundleVersionに指定される値です。通常、バグ修正やマイナーチェンジなど、同一のバージョン内でのビルドを区別するために使用されます。この番号は連続する整数値であることが一般的です。

### `native_app_update`イベントの発生条件

SDKにおいて、native\_app\_updateというイベントは、アプリのバージョンが更新された際に発生します。ただし、このイベントが発生するのは**version\_codeの変更時ではなく、version\_nameが更新された場合**に限られます。

つまり、アプリが新しいビルドに更新され、version\_codeが変更されてもnative\_app\_updateイベントは発生しません。逆に、アプリのメジャーアップデートや機能追加によってversion\_nameが更新されると、このイベントがトリガーされ、アプリ内での適切な処理が行われます。


---

# 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, and the optional `goal` query parameter:

```
GET https://app.developers.karte.io/ios-sdk-appendix/appendix-ios-version-update.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
