1.0.43 • Published 6 years ago

@edropin/store-svc v1.0.43

Weekly downloads
22
License
UNLICENSED
Repository
-
Last release
6 years ago

e_dropin_store

EDropinStore - JavaScript client for e_dropin_store Store service for eDropin This SDK is automatically generated by the Swagger Codegen project:

  • API version: 1.0.11
  • Package version: 1.0.11
  • Build package: io.swagger.codegen.languages.JavascriptClientCodegen

Installation

For Node.js

npm

To publish the library as a npm, please follow the procedure in "Publishing npm packages".

Then install it via:

npm install e_dropin_store --save
Local development

To use the library locally without publishing to a remote npm registry, first install the dependencies by changing into the directory containing package.json (and this README). Let's call this JAVASCRIPT_CLIENT_DIR. Then run:

npm install

Next, link it globally in npm with the following, also from JAVASCRIPT_CLIENT_DIR:

npm link

Finally, switch to the directory you want to use your e_dropin_store from, and run:

npm link /path/to/<JAVASCRIPT_CLIENT_DIR>

You should now be able to require('e_dropin_store') in javascript files from the directory you ran the last command above from.

git

If the library is hosted at a git repository, e.g. https://github.com/GIT_USER_ID/GIT_REPO_ID then install it via:

    npm install GIT_USER_ID/GIT_REPO_ID --save

For browser

The library also works in the browser environment via npm and browserify. After following the above steps with Node.js and installing browserify with npm install -g browserify, perform the following (assuming main.js is your entry file, that's to say your javascript file where you actually use this library):

browserify main.js > bundle.js

Then include bundle.js in the HTML pages.

Webpack Configuration

Using Webpack you may encounter the following error: "Module not found: Error: Cannot resolve module", most certainly you should disable AMD loader. Add/merge the following section to your webpack config:

module: {
  rules: [
    {
      parser: {
        amd: false
      }
    }
  ]
}

Getting Started

Please follow the installation instruction and execute the following JS code:

var EDropinStore = require('e_dropin_store');

var defaultClient = EDropinStore.ApiClient.instance;

// Configure API key authorization: Authorization
var Authorization = defaultClient.authentications['Authorization'];
Authorization.apiKey = "YOUR API KEY"
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//Authorization.apiKeyPrefix['Authorization'] = "Token"

// Configure API key authorization: ClientKey
var ClientKey = defaultClient.authentications['ClientKey'];
ClientKey.apiKey = "YOUR API KEY"
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ClientKey.apiKeyPrefix['X-Client-Key'] = "Token"

var api = new EDropinStore.EsCartApi()

var itemId = "itemId_example"; // {String} Store Item Id

var body = new EDropinStore.EsCartItemInput(); // {EsCartItemInput} Cart Item that needs to be upserted


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.addItem(itemIdbody, callback);

Documentation for API Endpoints

All URIs are relative to http://localhost:9004

ClassMethodHTTP requestDescription
EDropinStore.EsCartApiaddItemPOST /cart/add-item/{itemId}Upsert item to cart
EDropinStore.EsCartApiapplyPromotionPOST /cart/apply-promotionPromotional codes and memberships can be entered here
EDropinStore.EsCartApicheckoutPOST /cart/checkoutEndpoint to charge the customer for the items in their cart.
EDropinStore.EsCartApiemptyCartDELETE /cartEmpty the user cart
EDropinStore.EsCartApiremoveItemPOST /cart/remove-item/{itemId}Delete a cart item
EDropinStore.EsCartApiupdateCartPOST /cartUpdate the cart
EDropinStore.EsCartApivalidatePOST /cart/validateValidate Cart for a currency to ensure all items are available and pricing is all up to date and there are not potential conflicts
EDropinStore.EsCurrencyExchangeApigetLatestExchangeGET /currency-exchangeGet the latest exchange rates data
EDropinStore.EsCustomersApigetUserCustomerGET /customersGet the users current customer information
EDropinStore.EsCustomersApilistAllCardsGET /customers/cardsRetrieve all saved cards for customer
EDropinStore.EsCustomersApiremoveCardDELETE /customers/cards/{cardId}Remove a card
EDropinStore.EsCustomersApiupdateCustomerPUT /customersUpdate a customer
EDropinStore.EsMembershipsApicreateMembershipPOST /membershipsCreate Membership
EDropinStore.EsMembershipsApideleteMembersTaskDELETE /memberships/{membershipId}/members/tasksDelete all members in the membership cloud tasks
EDropinStore.EsMembershipsApideleteMembershipDELETE /memberships/{membershipId}Delete an existing membership
EDropinStore.EsMembershipsApigetAllMembershipsGET /membershipsGet Memberships
EDropinStore.EsMembershipsApigetMembersGET /memberships/{membershipId}/membersGet members for a membership
EDropinStore.EsMembershipsApigetMembershipGET /memberships/{membershipId}Get a membership from eDropin
EDropinStore.EsMembershipsApiupdateMembersPUT /memberships/{membershipId}/membersUpdate an existing membership
EDropinStore.EsMembershipsApiupdateMembershipPUT /memberships/{membershipId}Update an existing membership
EDropinStore.EsMerchantsApienableBillingPOST /merchants/{merchantId}/enable-billingEnable billing
EDropinStore.EsMerchantsApigetMerchantGET /merchants/{merchantId}Get a Merchant from the directory
EDropinStore.EsMerchantsApilistMerchantFeedGET /merchants/{merchantId}/feedMerchant Feed
EDropinStore.EsMerchantsApiupdateFeeStructurePUT /merchants/{merchantId}/fee-structure/{itemType}Setup fee structure for merchant Admin Only
EDropinStore.EsMerchantsApiupdateMerchantPUT /merchants/{merchantId}Update Merchant
EDropinStore.EsOrderApigetOrderGET /orders/{orderId}Get order by id
EDropinStore.EsOrderApilistOrderItemsGET /orders/{orderId}/itemsList order items
EDropinStore.EsOrderApilistUserOrdersGET /ordersGet orders for current user
EDropinStore.EsOrderItemsApicreateChargePOST /order-items/{orderItemId}/chargeCreate an additional charge on an order item
EDropinStore.EsOrderItemsApicreateRefundPOST /order-items/{orderItemId}/refundsCreate a refund for an order item
EDropinStore.EsOrderItemsApicreateRefundRequestPOST /order-items/{orderItemId}/refund-requestsCreate a refund for an item
EDropinStore.EsOrderItemsApigetOrderItemGET /order-items/{orderItemId}Get the order item
EDropinStore.EsOrderItemsApilistOrderItemsByMerchantGET /order-itemsList merchant order items
EDropinStore.EsPermissionsApiacceptPermissionInvitePOST /permissions/accept-invite/{inviteToken}Accept a permission invite
EDropinStore.EsPermissionsApihasPermissionGET /permissions/{entityType}/{entityId}/accounts/{accountId}Check account has permission
EDropinStore.EsPermissionsApipaginatePermissionsGET /permissions/{entityType}/{entityId}/accountsGet permissions for entity
EDropinStore.EsPermissionsApiremovePermissionsForAccountDELETE /permissions/{entityType}/{entityId}/accounts/{accountId}Remove all permissions for account
EDropinStore.EsPermissionsApisendPermissionInvitePOST /permissions/{entityType}/{entityId}/send-inviteSend a permission invite
EDropinStore.EsPermissionsApisetPermissionPUT /permissions/{entityType}/{entityId}/accounts/{accountId}Set account permission
EDropinStore.EsStoreApicreateStoreItemPOST /storeCreate a store item
EDropinStore.EsStoreApideleteStoreItemDELETE /store/{itemId}Delete an existing Store Item
EDropinStore.EsStoreApigetMultipleStoreItemsGET /store/get-multiGet multiple store items from the directory
EDropinStore.EsStoreApigetStoreItemGET /store/{itemId}Get a store item from the directory
EDropinStore.EsStoreApilistStoreItemsGET /storeGet all store items for merchant
EDropinStore.EsStoreApiupdateStoreItemPUT /store/{itemId}Update a store item
EDropinStore.EsSubscriptionsApideleteSubscriptionDELETE /subscriptions/{subscriptionId}Cancel a subscription
EDropinStore.EsSubscriptionsApiretrieveSubscriptionsByIdGET /subscriptions/retrieve-multiGet multiple subscriptions. Must all belong to one merchant ID
EDropinStore.EsTransactionsApirefreshChargeTransactionPOST /charge-transactions/{transactionId}/refreshRefreshes a charge transaction against the stripe account in order to make sure all amounts are synced
EDropinStore.EsTransactionsApiretrieveChargeTransactionsByIdGET /charge-transactions/retrieve-multiGet multiple charge transactions. Must all belong to one merchant ID
EDropinStore.EsTransactionsApiretrieveRefundTransactionsByIdGET /refund-transactions/retrieve-multiGet multiple refund transactions. Must all belong to one merchant ID
EDropinStore.EsUserMembershipsApiaddUserMembershipPOST /user-membershipsAdd a membership to a user
EDropinStore.EsUserMembershipsApilistUserMembershipsGET /user-membershipsList current user memberships
EDropinStore.EsUserMembershipsApiremoveUserMembershipDELETE /user-memberships/{userMembershipId}Delete an existing membership
EDropinStore.EsUserMembershipsApiupdateUserMembershipPUT /user-memberships/{userMembershipId}Update an existing user membership

Documentation for Models

Documentation for Authorization

Authorization

  • Type: API key
  • API key parameter name: Authorization
  • Location: HTTP header

AuthorizationOptional

  • Type: API key
  • API key parameter name: Authorization
  • Location: HTTP header

ClientKey

  • Type: API key
  • API key parameter name: X-Client-Key
  • Location: HTTP header
1.0.43

6 years ago

1.0.42

6 years ago

1.0.41

6 years ago

1.0.40

6 years ago

1.0.39

6 years ago

1.0.38

7 years ago

1.0.37

7 years ago

1.0.36

7 years ago

1.0.35

7 years ago

1.0.34

7 years ago

1.0.33

7 years ago

1.0.32

7 years ago

1.0.31

7 years ago

1.0.30

7 years ago

1.0.29

7 years ago

1.0.28

7 years ago

1.0.27

7 years ago

1.0.26

7 years ago

1.0.25

7 years ago

1.0.24

7 years ago

1.0.23

7 years ago

1.0.22

7 years ago

1.0.21

7 years ago

1.0.20

7 years ago

1.0.19

7 years ago

1.0.18

7 years ago

1.0.17

7 years ago

1.0.16

7 years ago

1.0.15

7 years ago

1.0.14

7 years ago

1.0.13

7 years ago

1.0.12

7 years ago

1.0.11

7 years ago

1.0.10

7 years ago

1.0.9

7 years ago

1.0.8

7 years ago

1.0.7

7 years ago

1.0.6

7 years ago

1.0.5

7 years ago

1.0.4

7 years ago

1.0.3

7 years ago

1.0.2

7 years ago

1.0.1

7 years ago

1.0.0

7 years ago