{"id":47060246,"url":"https://github.com/fluidcoins/react-native_fluidcoins-pay","last_synced_at":"2026-03-12T03:38:32.435Z","repository":{"id":38187494,"uuid":"416031313","full_name":"fluidcoins/react-native_fluidcoins-pay","owner":"fluidcoins","description":"Connect your React native app with FluidcoinsPay","archived":false,"fork":false,"pushed_at":"2022-06-09T19:28:34.000Z","size":753,"stargazers_count":1,"open_issues_count":1,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-10-10T05:26:11.753Z","etag":null,"topics":["payments","react-native"],"latest_commit_sha":null,"homepage":"https://fluidcoins.com","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/fluidcoins.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-10-11T17:51:03.000Z","updated_at":"2023-01-15T21:27:42.000Z","dependencies_parsed_at":"2022-08-18T07:16:50.657Z","dependency_job_id":null,"html_url":"https://github.com/fluidcoins/react-native_fluidcoins-pay","commit_stats":null,"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"purl":"pkg:github/fluidcoins/react-native_fluidcoins-pay","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fluidcoins%2Freact-native_fluidcoins-pay","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fluidcoins%2Freact-native_fluidcoins-pay/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fluidcoins%2Freact-native_fluidcoins-pay/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fluidcoins%2Freact-native_fluidcoins-pay/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fluidcoins","download_url":"https://codeload.github.com/fluidcoins/react-native_fluidcoins-pay/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fluidcoins%2Freact-native_fluidcoins-pay/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30414489,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-12T00:40:14.898Z","status":"online","status_checked_at":"2026-03-12T02:00:07.260Z","response_time":114,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["payments","react-native"],"created_at":"2026-03-12T03:38:31.919Z","updated_at":"2026-03-12T03:38:32.430Z","avatar_url":"https://github.com/fluidcoins.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Fluidcoins Pay React Native SDK\n\nFluidcoins Pay.js is quick and secure way to receive crypto payments in your application. It works with all Javascript frameworks\n## Documentation\n\n## Getting Started\n1: Register a merchant account on [Fluidcoins](https://fluidcoins.com/) and get your public API key\n\n## Installation\n\nYou can install the package via NPM or Yarn;\n\n```\nnpm i @fluidcoins/react-native-fluidcoins-pay\n\n```\n\nOR\n\n```\nyarn add @fluidcoins/react-native-fluidcoins-pay\n```\nAlso install **`react-native-webview`** because it's a peer dependency for this package.\n\n## Usage\n\n**Hooks**\n\n```\nimport * as React from 'react';\n\nimport { StyleSheet, View, TouchableOpacity, Text, TextInput,} from 'react-native';\nimport { FluidcoinsProvider, useFluidcoinsPay } from 'react-native-fluidcoins-pay';\n\nexport default function App() {\n  const [value, setValue] = React.useState('0');\n\n  const config = {\n    publicKey: 'YOUR_FLUIDCOINS_PUBLIC_KEY',\n    email: 'johndoe@test.com',\n    onSuccess: () =\u003e {},\n    amount: parseInt(value, 10) * 100,\n  };\n\n  const Button = () =\u003e {\n    const { open } = useFluidcoinsPay();\n\n    return (\n      \u003cView style={styles.button}\u003e\n        \u003cTouchableOpacity onPress={open}\u003e\n          \u003cText style={styles.text}\u003ePay {value}\u003c/Text\u003e\n        \u003c/TouchableOpacity\u003e\n      \u003c/View\u003e\n    );\n  };\n  return (\n    \u003cView style={styles.container}\u003e\n      \u003cFluidcoinsProvider {...config}\u003e\n        \u003cTextInput\n          style={styles.input}\n          value={value}\n          onChangeText={(v) =\u003e setValue(v)}\n        /\u003e\n        \u003cButton /\u003e\n      \u003c/FluidcoinsProvider\u003e\n    \u003c/View\u003e\n  );\n}\n\nconst styles = StyleSheet.create({\n  container: {\n    flex: 1,\n    alignItems: 'center',\n    padding: 64,\n  },\n  box: {\n    width: 60,\n    height: 60,\n    marginVertical: 20,\n  },\n  button: {\n    backgroundColor: 'blue',\n    paddingHorizontal: 16,\n    paddingVertical: 16,\n    borderRadius: 4,\n    width: '100%',\n  },\n  text: {\n    color: '#fff',\n    fontSize: 18,\n    textAlign: 'center',\n  },\n  input: {\n    borderColor: 'green',\n    borderWidth: 1,\n    borderRadius: 2,\n    marginBottom: 8,\n    padding: 10,\n    width: '100%',\n  },\n});\n\n```\n\n## Configurations Options\n\n- `publicKey`\n- `amount`\n- `email`\n- `onSuccess`\n- `onLoad` (optional)\n- `onClose` (optional)\n- `name` (optional)\n- `phone` (optional)\n- `metadata` (optional)\n\n**_`publicKey`_**\n\n**REQUIRED**\n\nThis is your Fluidcoins public API key from the [Fluidcoins](https://fluidcoins.com/) dashboard.\n\n**_`amount`_**\n\n**REQUIRED**\n\nThis is amount in **KOBO** you'd want to collect from the customer.\n\n**NOTE: The miumum amount is 500 NGN**\n\n```\nconst config = {\n    publicKey: 'YOUR_FLUIDCOINS_PUBLIC_KEY',\n    amount: parseInt(value, 10) * 100,\n  };\n```\n\n**_`email`_**\n\n**REQUIRED**\n\nThis is the email address of the customer\n\n```\nconst config = {\n    publicKey: 'YOUR_FLUIDCOINS_PUBLIC_KEY',\n    amount: parseInt(value, 10) * 100,\n    email: 'johndoe@test.com',\n  };\n```\n\n**_`onSuccess`_**\n\n**REQUIRED**\n\nThis is function that will be called when a successful transaction occurs.\n\n```\nconst config = {\n  publicKey: 'YOUR_FLUIDCOINS_PUBLIC_KEY',\n  amount: parseInt(value, 10) * 100,\n  email: 'johndoe@test.com',\n  onSuccess: (data) =\u003e {\n    console.log(data)\n  }\n};\n```\n\n A JSON payload is passed as argument with the structure below;\n\n```\n{\n    reference: TRANS_REFERENCE,\n    coin: 'BTC',\n    human_readable_amount: 1000,\n    payment_status: 'underpaid | overpaid | paid_in_full'\n}\n```\n\u003e Payment status could be overpaid, underpaid or paid_in_full\n\n\n**_`onClose`_**\n\n**OPTIONAL**\n\nThis optional closure is called when a user closes the Fluidcoins Widget. It takes no argument\n\n```\nconst config = {\n  publicKey: 'YOUR_FLUIDCOINS_PUBLIC_KEY',\n  amount: parseInt(value, 10) * 100,\n  email: 'johndoe@test.com',\n  onSuccess: (data) =\u003e {\n    console.log(data)\n  },\n  onClose: () =\u003e {},\n};\n```\n\n\n**_`name`_**\n\n**OPTIONAL**\n\nThis optional parameter; which is the name of customer who want to initiate the transaction. It reflects on the  [Fluidcoins dashboard](https://fluidcoins.com/).\n\n```\nconst config = {\n  publicKey: 'YOUR_FLUIDCOINS_PUBLIC_KEY',\n  amount: parseInt(value, 10) * 100,\n  email: 'johndoe@test.com',\n  onSuccess: (data) =\u003e {\n    console.log(data)\n  },\n  onClose: () =\u003e {},\n  name: 'Seun Akanni'\n};\n```\n\n\n**_`phone`_**\n\n**OPTIONAL**\n\nThis optional parameter; which is the phone number of customer who want to initiate the transaction. It reflects on the  [Fluidcoins dashboard](https://fluidcoins.com/).\n\n```\nconst config = {\n  publicKey: 'YOUR_FLUIDCOINS_PUBLIC_KEY',\n  amount: parseInt(value, 10) * 100,\n  email: 'johndoe@test.com',\n  onSuccess: (data) =\u003e {\n    console.log(data)\n  },\n  onClose: () =\u003e {},\n  name: 'Seun Akanni',\n  phone: '+2348090909090',\n};\n```\n\n**_`reference`_**\n\n**OPTIONAL**\n\nThis optional parameter; which is used to identify the initiated transaction.\n\n**NOTE** : It must be unique per transaction\n\n```\nconst config = {\n  publicKey: 'YOUR_FLUIDCOINS_PUBLIC_KEY',\n  amount: parseInt(value, 10) * 100,\n  email: 'johndoe@test.com',\n  onSuccess: (data) =\u003e {\n    console.log(data)\n  },\n  onClose: () =\u003e {},\n  name: 'Seun Akanni',\n  phone: '+2348090909090',\n  reference: 'random-unique-identifier'\n};\n```\n\n\n**_`metadata`_**\n\n**OPTIONAL**\n\nThis optional parameter, which is should contain data you will like to be passed via webhooks about the transaction.\nNOTE: The _metadata_ must be an **OBJECT**\n\n```\nconst config = {\n  publicKey: 'YOUR_FLUIDCOINS_PUBLIC_KEY',\n  amount: parseInt(value, 10) * 100,\n  email: 'johndoe@test.com',\n  onSuccess: (data) =\u003e {\n    console.log(data)\n  },\n  onClose: () =\u003e {},\n  name: 'Seun Akanni',\n  phone: '+2348090909090',\n  reference: 'random-unique-identifier'\n  metadata: {\n      key: 1\n  }\n};\n```\n\n\n**_`currency`_**\n\n**OPTIONAL**\n\nPossible values are the ISO 4217 currency codes, such as \"USD\" for the US dollar\"\n\nNOTE: It defaults to default currency set on your [Fluidcoins](https://fluidcoins.com/)  dashboard.\n\n```\nconst config = {\n  publicKey: 'YOUR_FLUIDCOINS_PUBLIC_KEY',\n  amount: parseInt(value, 10) * 100,\n  email: 'johndoe@test.com',\n  onSuccess: (data) =\u003e {\n    console.log(data)\n  },\n  onClose: () =\u003e {},\n  name: 'Seun Akanni',\n  phone: '+2348090909090',\n  reference: 'random-unique-identifier'\n  metadata: {\n      key: 1\n  },\n  currency: 'USD'\n};\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffluidcoins%2Freact-native_fluidcoins-pay","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffluidcoins%2Freact-native_fluidcoins-pay","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffluidcoins%2Freact-native_fluidcoins-pay/lists"}