Shipping Address Picker
selectShippingAddress() opens Kakao's shipping address picker and returns the selected address ID as Promise<number> on Android, iOS, and web.
The user must be logged in. The app must have permission to use the shipping_address consent item, and the user must consent to it.
For Expo on Android, enable the picker callback in the core config plugin and run prebuild again:
[
"@react-native-kakao/core",
{
"nativeAppKey": "{{native app key}}",
"android": {
"authCodeHandlerActivity": true,
"shippingAddressHandlerActivity": true
}
}
]
For bare Android apps, register com.kakao.sdk.auth.AppsHandlerActivity with android:exported="true" and a browsable VIEW intent filter for kakao{NATIVE_APP_KEY}://address. See the Android setup.
Call the function directly from a button press so the browser can open the picker popup.
import { selectShippingAddress } from '@react-native-kakao/user';
const onPress = async () => {
const addressId = await selectShippingAddress();
return addressId;
};
This method returns an ID, without retrieving the address details. Kakao's v2 REST shipping address API can retrieve a specific address by address_id. The pinned Kakao SDKs do not expose that v2 API.
SDK errors reject the promise. Cancelling the native picker also rejects it. In JavaScript SDK 2.8.4, used by the example, closing the popup without a response can leave its promise pending; the wrapper preserves that SDK behavior.