Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/main-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
- name: Configure git
run: |
git config user.name "bolt-ci"
git config user.email "bolt-ci@bolt.com"
git config user.email "bolt-ci@boltapp.com"

- uses: ./.github/actions/setup

Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ Bolt React Native SDK for payments. Provides Credit Card tokenization, 3D Secure

## Architecture

- **Credit Card (WebView)** — WebView-based, loading secure pages from `connect.bolt.com`. Card data never touches your app (PCI SAQ A compliant).
- **Credit Card (WebView)** — WebView-based, loading secure pages from `connect.boltapp.com`. Card data never touches your app (PCI SAQ A compliant).
- **Credit Card (Native)** — Platform-native text fields (`UITextField` on iOS, `EditText` on Android). Card data stays in native memory, never enters the JS heap. Requires Bolt PCI SSS certification for SAQ A — see [Native Credit Card (Beta)](#7-native-credit-card-beta) below.
- **Apple Pay & Google Pay** — Native Fabric view components for buttons (`PKPaymentButton` on iOS, `PayButton` on Android) with TurboModules for the payment sheet.

Expand Down Expand Up @@ -256,7 +256,7 @@ function CheckoutScreen() {

### 6. Styling

Apply global styles to all Bolt components, or per-element styles at creation time. Uses the v3 CSS custom property format (`--bolt-{target}-{property}`). See [Bolt styling docs](https://help.bolt.com/products/checkout/embeddable-checkout/api-implementation/styling/style-components-v3/) for the full list of tokens.
Apply global styles to all Bolt components, or per-element styles at creation time. Uses the v3 CSS custom property format (`--bolt-{target}-{property}`). See [Bolt styling docs](https://help.boltapp.com/products/checkout/embeddable-checkout/api-implementation/styling/style-components-v3/) for the full list of tokens.

```typescript
// Global styles — applies to all elements
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,15 +53,15 @@ class BoltTokenizer(environment: String) {
when (environment) {
"production" -> {
baseURL = "https://production.bolttk.com"
fallbackURL = "https://tokenizer.bolt.com"
fallbackURL = "https://tokenizer.boltapp.com"
}
"sandbox" -> {
baseURL = "https://sandbox.bolttk.com"
fallbackURL = "https://tokenizer-sandbox.bolt.com"
fallbackURL = "https://tokenizer-sandbox.boltapp.com"
}
else -> { // staging
baseURL = "https://staging.bolttk.com"
fallbackURL = "https://tokenizer-staging.bolt.com"
fallbackURL = "https://tokenizer-staging.boltapp.com"
}
}
}
Expand Down
6 changes: 3 additions & 3 deletions ios/BoltTokenizer.swift
Original file line number Diff line number Diff line change
Expand Up @@ -49,13 +49,13 @@ class BoltTokenizer {
switch environment {
case "sandbox":
baseURL = "https://sandbox.bolttk.com"
fallbackURL = "https://tokenizer-sandbox.bolt.com"
fallbackURL = "https://tokenizer-sandbox.boltapp.com"
case "staging":
baseURL = "https://staging.bolttk.com"
fallbackURL = "https://tokenizer-staging.bolt.com"
fallbackURL = "https://tokenizer-staging.boltapp.com"
default: // production (safest default for unknown env strings)
baseURL = "https://production.bolttk.com"
fallbackURL = "https://tokenizer.bolt.com"
fallbackURL = "https://tokenizer.boltapp.com"
}
}

Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@boltpay/react-native",
"version": "0.9.11",
"version": "0.10.0",
"description": "Bolt React Native SDK",
"license": "MIT",
"main": "./lib/module/index.js",
Expand Down Expand Up @@ -60,7 +60,7 @@
"type": "git",
"url": "git+https://github.com/BoltApp/bolt-react-native-sdk.git"
},
"author": "BoltOwner <bolt@bolt.com> (https://www.bolt.com)",
"author": "BoltOwner <bolt@boltapp.com> (https://www.boltapp.com)",
"bugs": {
"url": "https://github.com/BoltApp/bolt-react-native-sdk/issues"
},
Expand Down
2 changes: 1 addition & 1 deletion src/__tests__/ApplePayWebView.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ jest.mock('../native/NativeApplePay', () => ({
jest.mock('../client/useBolt', () => ({
useBolt: () => ({
publishableKey: 'pk_test_123',
baseUrl: 'https://connect.bolt.com',
baseUrl: 'https://connect.boltapp.com',
language: 'en',
}),
}));
Expand Down
6 changes: 3 additions & 3 deletions src/__tests__/CreditCard.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ describe('Bolt', () => {
it('should create a Bolt instance with publishableKey', () => {
const bolt = new Bolt({ publishableKey: 'pk_test_123' });
expect(bolt.publishableKey).toBe('pk_test_123');
expect(bolt.baseUrl).toBe('https://connect.bolt.com');
expect(bolt.baseUrl).toBe('https://connect.boltapp.com');
expect(bolt.language).toBe('en');
});

Expand All @@ -30,15 +30,15 @@ describe('Bolt', () => {
publishableKey: 'pk_test_123',
environment: 'sandbox',
});
expect(bolt.baseUrl).toBe('https://connect-sandbox.bolt.com');
expect(bolt.baseUrl).toBe('https://connect-sandbox.boltapp.com');
});

it('should use staging URL when environment is staging', () => {
const bolt = new Bolt({
publishableKey: 'pk_test_123',
environment: 'staging',
});
expect(bolt.baseUrl).toBe('https://connect-staging.bolt.com');
expect(bolt.baseUrl).toBe('https://connect-staging.boltapp.com');
});

it('should throw when publishableKey is missing', () => {
Expand Down
4 changes: 2 additions & 2 deletions src/__tests__/GoogleWallet.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,8 @@ jest.mock('../client/useBolt', () => ({
useBolt: () => ({
publishableKey: 'pk_test_123',
environment: 'production' as const,
baseUrl: 'https://connect.bolt.com',
apiUrl: 'https://api.bolt.com',
baseUrl: 'https://connect.boltapp.com',
apiUrl: 'https://api.boltapp.com',
apiHeaders: () => ({ 'X-Publishable-Key': 'pk_test_123' }),
}),
}));
Expand Down
4 changes: 2 additions & 2 deletions src/__tests__/NativeCreditCard.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ jest.mock('../native/NativeBoltCardFieldModule', () => ({
jest.mock('../client/useBolt', () => ({
useBolt: () => ({
publishableKey: 'pk_test_123',
baseUrl: 'https://connect.bolt.com',
apiUrl: 'https://api.bolt.com',
baseUrl: 'https://connect.boltapp.com',
apiUrl: 'https://api.boltapp.com',
}),
}));

Expand Down
4 changes: 2 additions & 2 deletions src/__tests__/NativeCreditCardComponent.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ jest.mock('../native/NativeCreditCardField', () => {
jest.mock('../client/useBolt', () => ({
useBolt: () => ({
publishableKey: 'pk_test_456',
baseUrl: 'https://connect-sandbox.bolt.com',
apiUrl: 'https://api-sandbox.bolt.com',
baseUrl: 'https://connect-sandbox.boltapp.com',
apiUrl: 'https://api-sandbox.boltapp.com',
}),
}));

Expand Down
6 changes: 3 additions & 3 deletions src/__tests__/googlePayApi.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,12 @@ describe('fetchGooglePayAPMConfig', () => {
json: () => Promise.resolve(mockAPMConfig),
});

await fetchGooglePayAPMConfig('https://api.bolt.com', {
await fetchGooglePayAPMConfig('https://api.boltapp.com', {
'X-Publishable-Key': 'pk_test_abc',
});

expect(mockFetch).toHaveBeenCalledWith(
'https://api.bolt.com/v1/apm_config/googlepay',
'https://api.boltapp.com/v1/apm_config/googlepay',
expect.objectContaining({
method: 'GET',
headers: { 'X-Publishable-Key': 'pk_test_abc' },
Expand All @@ -53,7 +53,7 @@ describe('fetchGooglePayAPMConfig', () => {
});

await expect(
fetchGooglePayAPMConfig('https://api.bolt.com', {
fetchGooglePayAPMConfig('https://api.boltapp.com', {
'X-Publishable-Key': 'bad_key',
})
).rejects.toThrow('Failed to fetch Google Pay config: 401 Unauthorized');
Expand Down
4 changes: 2 additions & 2 deletions src/__tests__/useCreditCardController.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ jest.mock('react-native-webview', () => ({}));
jest.mock('../client/useBolt', () => ({
useBolt: () => ({
publishableKey: 'pk_test_123',
baseUrl: 'https://connect.bolt.com',
apiUrl: 'https://api-staging.bolt.com',
baseUrl: 'https://connect.boltapp.com',
apiUrl: 'https://api-staging.boltapp.com',
getOnPageStyles: () => undefined,
}),
}));
Expand Down
6 changes: 3 additions & 3 deletions src/__tests__/useNativeCreditCardController.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ jest.mock('../native/NativeBoltCardFieldModule', () => ({
jest.mock('../client/useBolt', () => ({
useBolt: () => ({
publishableKey: 'pk_test_123',
baseUrl: 'https://connect.bolt.com',
apiUrl: 'https://api-staging.bolt.com',
baseUrl: 'https://connect.boltapp.com',
apiUrl: 'https://api-staging.boltapp.com',
}),
}));

Expand Down Expand Up @@ -100,7 +100,7 @@ describe('useNativeCreditCardController', () => {
expect(mockTokenize).toHaveBeenCalledWith(
42,
'pk_test_123',
'https://api-staging.bolt.com'
'https://api-staging.boltapp.com'
);
expect(tokenResult).toEqual({
token: 'bolt_cc_test123',
Expand Down
4 changes: 2 additions & 2 deletions src/bridge/buildIframeUrl.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ export interface IframeUrlParams {
* by dom-host.utils.ts in the storm codebase.
*
* Example output:
* https://connect.bolt.com/src/iframes/credit-card-input/index.html?
* origin=https%3A%2F%2Fconnect.bolt.com&publishableKey=pk_123&
* https://connect.boltapp.com/src/iframes/credit-card-input/index.html?
* origin=https%3A%2F%2Fconnect.boltapp.com&publishableKey=pk_123&
* l=en&transport=rn-webview&checkoutPageID=uuid
*/
export const buildIframeUrl = (params: IframeUrlParams): string => {
Expand Down
12 changes: 6 additions & 6 deletions src/client/Bolt.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,15 @@ export interface BoltConfig {
}

const ENVIRONMENT_URLS: Record<string, string> = {
production: 'https://connect.bolt.com',
sandbox: 'https://connect-sandbox.bolt.com',
staging: 'https://connect-staging.bolt.com',
production: 'https://connect.boltapp.com',
sandbox: 'https://connect-sandbox.boltapp.com',
staging: 'https://connect-staging.boltapp.com',
};

const API_URLS: Record<string, string> = {
production: 'https://api.bolt.com',
sandbox: 'https://api-sandbox.bolt.com',
staging: 'https://api-staging.bolt.com',
production: 'https://api.boltapp.com',
sandbox: 'https://api-sandbox.boltapp.com',
staging: 'https://api-staging.boltapp.com',
};

export class Bolt {
Expand Down
2 changes: 1 addition & 1 deletion src/native/NativeBoltCardFieldModule.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export interface Spec extends TurboModule {
*
* @param viewTag React tag of the mounted BoltCreditCardField
* @param publishableKey Bolt publishable key for Authorization header
* @param apiUrl Bolt API base URL (api.bolt.com or api-sandbox.bolt.com)
* @param apiUrl Bolt API base URL (api.boltapp.com or api-sandbox.boltapp.com)
* @returns JSON-encoded TokenResult or error
*/
tokenize(
Expand Down
Loading