# Server SDKs

> Install Paystack's official server SDKs for Node.js, Python and Ruby, and find community libraries for other languages.

Paystack's server SDKs call the [Paystack API](/api) from your backend with your secret key. Use one to initialize and verify transactions, manage customers, send transfers and handle any other server-side call. If your language isn't listed, call the API with any HTTP client.

<callout type="danger" title="Keep your secret key on your server">

Read your secret key from an environment variable or a secrets manager. Don't commit it to source control or ship it in frontend or mobile code. See [API keys](/developer-tools/integration/api-keys).

</callout>

## Official SDKs

<table>
<thead>
  <tr>
    <th>
      SDK
    </th>
    
    <th>
      Package
    </th>
    
    <th>
      Repository
    </th>
  </tr>
</thead>

<tbody>
  <tr>
    <td>
      Node.js
    </td>
    
    <td>
      <a href="https://www.npmjs.com/package/@paystack/paystack-sdk" rel="nofollow">
        <code>
          @paystack/paystack-sdk
        </code>
      </a>
    </td>
    
    <td>
      <a href="https://github.com/PaystackOSS/paystack-node" rel="nofollow">
        <code>
          PaystackOSS/paystack-node
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      Python
    </td>
    
    <td>
      <a href="https://pypi.org/project/paystack-sdk/" rel="nofollow">
        <code>
          paystack-sdk
        </code>
      </a>
    </td>
    
    <td>
      <a href="https://github.com/PaystackOSS/paystack-python" rel="nofollow">
        <code>
          PaystackOSS/paystack-python
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      Ruby
    </td>
    
    <td>
      <a href="https://rubygems.org/gems/paystack-ruby" rel="nofollow">
        <code>
          paystack-ruby
        </code>
      </a>
    </td>
    
    <td>
      <a href="https://github.com/PaystackOSS/paystack-ruby" rel="nofollow">
        <code>
          PaystackOSS/paystack-ruby
        </code>
      </a>
    </td>
  </tr>
</tbody>
</table>

### Install

<code-tabs>
<template v-slot:nodejs="">

```bash
npm install @paystack/paystack-sdk
```

</template>

<template v-slot:python="">

```bash
pip install paystack-sdk
```

</template>

<template v-slot:ruby="">

```bash
gem install paystack-ruby
```

</template>
</code-tabs>

### Initialize a transaction

Each example reads your secret key from the `PAYSTACK_SECRET_KEY` environment variable and calls [Initialize Transaction](/api/transaction#initialize). The `amount` is in <localized-value page-key="markets" path="subunit">



</localized-value>

. Use your test secret key (`sk_test_...`) while you build.

<code-tabs>
<template v-slot:nodejs="">

```js
const { Paystack } = require('@paystack/paystack-sdk');

const paystack = new Paystack(process.env.PAYSTACK_SECRET_KEY);

paystack.transaction
  .initialize({ email: 'customer@example.com', amount: 20000 })
  .then((response) => console.log(response.data.authorization_url))
  .catch((error) => console.error(error));
```

</template>

<template v-slot:python="">

```python
import os

import paystack

paystack.api_key = os.environ['PAYSTACK_SECRET_KEY']

response = paystack.Transaction.initialize(email='customer@example.com', amount=20000)
print(response)
```

</template>

<template v-slot:ruby="">

```ruby
require "paystack"

paystack = Paystack::Client.new(ENV.fetch("PAYSTACK_SECRET_KEY"))

result = paystack.transaction.initialize({ email: "customer@example.com", amount: 20000 })
puts result.data[:authorization_url]
```

</template>
</code-tabs>

Send the customer to the returned `authorization_url`, or pass the `access_code` to [InlineJS](/developer-tools/inline-js#resume-transaction) to complete the payment on your page. Then [verify the payment](/payments/online/verify-payments) on your server before you deliver value.

Each repository's README lists every resource and method the SDK supports.

## Community server libraries

<callout type="warning">

Community maintainers own these libraries, not Paystack. If you have an issue with one, contact the maintainer or open an issue on its repository.

</callout>

<table>
<thead>
  <tr>
    <th>
      Language
    </th>
    
    <th>
      Library
    </th>
    
    <th>
      Repository
    </th>
  </tr>
</thead>

<tbody>
  <tr>
    <td>
      .Net
    </td>
    
    <td>
      Paystack .Net
    </td>
    
    <td>
      <a href="https://github.com/adebisi-fa/paystack-dotnet" rel="nofollow">
        <code>
          adebisi-fa/paystack-dotnet
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      .Net
    </td>
    
    <td>
      Paystack .Net SDK
    </td>
    
    <td>
      <a href="https://github.com/developerslearnit/Paystack.Net.SDK" rel="nofollow">
        <code>
          developerslearnit/Paystack.Net.SDK
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      Erlang/OTP (rebar3)
    </td>
    
    <td>
      Erl Paystack
    </td>
    
    <td>
      <a href="https://github.com/abimbola/erlpaystack" rel="nofollow">
        <code>
          abimbola/erlpaystack
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      Go
    </td>
    
    <td>
      Paystack Go
    </td>
    
    <td>
      <a href="https://github.com/rpip/paystack-go" rel="nofollow">
        <code>
          rpip/paystack-go
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      Groovy/Grails
    </td>
    
    <td>
      Paystack Grails
    </td>
    
    <td>
      <a href="https://github.com/dubems/paystack-grails" rel="nofollow">
        <code>
          dubems/paystack-grails
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      Java
    </td>
    
    <td>
      Paystack Java
    </td>
    
    <td>
      <a href="https://github.com/SeunAdelekan/PaystackJava" rel="nofollow">
        <code>
          SeunAdelekan/PaystackJava
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      NodeJS
    </td>
    
    <td>
      Paystack
    </td>
    
    <td>
      <a href="https://github.com/kehers/paystack" rel="nofollow">
        <code>
          kehers/paystack
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      NodeJS
    </td>
    
    <td>
      Paystack API
    </td>
    
    <td>
      <a href="https://github.com/pariola/paystack" rel="nofollow">
        <code>
          pariola/paystack
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      PHP
    </td>
    
    <td>
      CakePHP Paystack
    </td>
    
    <td>
      <a href="https://github.com/jtad009/cakephp-paystack" rel="nofollow">
        <code>
          jtad009/cakephp-paystack
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      PHP
    </td>
    
    <td>
      Cashier Paystack
    </td>
    
    <td>
      <a href="https://github.com/wisdomanthoni/cashier-paystack" rel="nofollow">
        <code>
          wisdomanthoni/cashier-paystack
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      PHP
    </td>
    
    <td>
      Laravel Paystack
    </td>
    
    <td>
      <a href="https://github.com/unicodeveloper/laravel-paystack" rel="nofollow">
        <code>
          unicodeveloper/laravel-paystack
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      PHP
    </td>
    
    <td>
      Paystack PHP
    </td>
    
    <td>
      <a href="https://github.com/perfectmak/paystack-php" rel="nofollow">
        <code>
          perfectmak/paystack-php
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      PHP
    </td>
    
    <td>
      Paystack
    </td>
    
    <td>
      <a href="https://github.com/matscode/paystack" rel="nofollow">
        <code>
          matscode/paystack
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      Python
    </td>
    
    <td>
      Py Paystack
    </td>
    
    <td>
      <a href="https://github.com/edwardpopoola/pypaystack" rel="nofollow">
        <code>
          edwardpopoola/pypaystack
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      Python
    </td>
    
    <td>
      Paystack
    </td>
    
    <td>
      <a href="https://github.com/ojengwa/paystack" rel="nofollow">
        <code>
          ojengwa/paystack
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      Python
    </td>
    
    <td>
      Paystack Python
    </td>
    
    <td>
      <a href="https://github.com/andela-sjames/paystack-python" rel="nofollow">
        <code>
          andela-sjames/paystack-python
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      Python
    </td>
    
    <td>
      Python Paystack
    </td>
    
    <td>
      <a href="https://github.com/Chibuzor-IN/python-paystack" rel="nofollow">
        <code>
          Chibuzor-IN/python-paystack
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      Python
    </td>
    
    <td>
      Py Paystack
    </td>
    
    <td>
      <a href="https://gitlab.com/frier17/pypaystack" rel="nofollow">
        frier17/pypaystack
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      R
    </td>
    
    <td>
      Paystack
    </td>
    
    <td>
      <a href="https://github.com/ebinabo/paystack" rel="nofollow">
        <code>
          ebinabo/paystack
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      Ruby
    </td>
    
    <td>
      Paystackr
    </td>
    
    <td>
      <a href="https://github.com/ojengwa/paystackr" rel="nofollow">
        <code>
          ojengwa/paystackr
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      Ruby
    </td>
    
    <td>
      Paystack Ruby
    </td>
    
    <td>
      <a href="https://github.com/IkoroVictor/paystack-ruby" rel="nofollow">
        <code>
          IkoroVictor/paystack-ruby
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      Ruby
    </td>
    
    <td>
      Paystack Ruby API
    </td>
    
    <td>
      <a href="https://github.com/samuel52/PaystackRubyApi" rel="nofollow">
        <code>
          samuel52/PaystackRubyApi
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      Yii
    </td>
    
    <td>
      Yii 2 Paystack
    </td>
    
    <td>
      <a href="https://github.com/smladeoye/yii2-paystack" rel="nofollow">
        <code>
          smladeoye/yii2-paystack
        </code>
      </a>
    </td>
  </tr>
</tbody>
</table>

## Community client libraries

These wrap Paystack Popup or the mobile SDKs for frontend and mobile frameworks. They run on the customer's device, so use them with your public key only. For Flutter, Paystack maintains the official [Flutter SDK](/developer-tools/mobile-sdks/flutter).

<table>
<thead>
  <tr>
    <th>
      Framework
    </th>
    
    <th>
      Library
    </th>
    
    <th>
      Repository
    </th>
  </tr>
</thead>

<tbody>
  <tr>
    <td>
      Angular
    </td>
    
    <td>
      Angular Paystack
    </td>
    
    <td>
      <a href="https://github.com/toniton/angular-paystack" rel="nofollow">
        <code>
          toniton/angular-paystack
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      Angular
    </td>
    
    <td>
      Angular 4 Paystack
    </td>
    
    <td>
      <a href="https://github.com/ashinzekene/angular4-paystack" rel="nofollow">
        <code>
          ashinzekene/angular4-paystack
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      Cordova
    </td>
    
    <td>
      Cordova Plugin Paystack
    </td>
    
    <td>
      <a href="https://github.com/tolu360/Cordova-Plugin-Paystack" rel="nofollow">
        <code>
          tolu360/Cordova-Plugin-Paystack
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      Cordova
    </td>
    
    <td>
      Paystack Cordova V2
    </td>
    
    <td>
      <a href="https://github.com/mrfoh/paystackcordovav2" rel="nofollow">
        <code>
          mrfoh/paystackcordovav2
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      Flutter
    </td>
    
    <td>
      Paystack Flutter
    </td>
    
    <td>
      <a href="https://github.com/mtellect/Flutter_Paystack" rel="nofollow">
        <code>
          mtellect/Flutter_Paystack
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      Flutter
    </td>
    
    <td>
      Flutter Paystack
    </td>
    
    <td>
      <a href="https://github.com/wilburt/flutter_paystack" rel="nofollow">
        <code>
          wilburt/flutter_paystack
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      NativeScript
    </td>
    
    <td>
      NativeScript Paystack
    </td>
    
    <td>
      <a href="https://github.com/jogboms/nativescript-paystack" rel="nofollow">
        <code>
          jogboms/nativescript-paystack
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      React JS
    </td>
    
    <td>
      React Paystack
    </td>
    
    <td>
      <a href="https://github.com/iamraphson/react-paystack" rel="nofollow">
        <code>
          iamraphson/react-paystack
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      React Native
    </td>
    
    <td>
      React Native Paystack
    </td>
    
    <td>
      <a href="https://github.com/tolu360/React-Native-Paystack" rel="nofollow">
        <code>
          tolu360/React-Native-Paystack
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      React Native
    </td>
    
    <td>
      React Native Paystack Webview
    </td>
    
    <td>
      <a href="https://github.com/just1and0/React-Native-Paystack-Webview" rel="nofollow">
        <code>
          just1and0/React-Native-Paystack-Webview
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      Vue JS
    </td>
    
    <td>
      Vue Paystack
    </td>
    
    <td>
      <a href="https://github.com/iamraphson/vue-paystack" rel="nofollow">
        <code>
          iamraphson/vue-paystack
        </code>
      </a>
    </td>
  </tr>
  
  <tr>
    <td>
      Xamarin
    </td>
    
    <td>
      PaystackInline Forms Plugin
    </td>
    
    <td>
      <a href="https://github.com/Akinnagbe/PaystackInline.Forms.Plugin" rel="nofollow">
        <code>
          Akinnagbe/PaystackInline.Forms.Plugin
        </code>
      </a>
    </td>
  </tr>
</tbody>
</table>
