# SdPublicProdApi.PurchasableItemEndpointsApi

All URIs are relative to *https://core-api.stardust.gg/v1*

Method | HTTP request | Description
------------- | ------------- | -------------
[**purchasableItemCreatePost**](PurchasableItemEndpointsApi.md#purchasableItemCreatePost) | **POST** /purchasable-item/create | Create Purchasable Item
[**purchasableItemGetAllGet**](PurchasableItemEndpointsApi.md#purchasableItemGetAllGet) | **GET** /purchasable-item/get-all | Get All Purchasable Items
[**purchasableItemGetGet**](PurchasableItemEndpointsApi.md#purchasableItemGetGet) | **GET** /purchasable-item/get | Get Purchasable Item
[**purchasableItemMutatePut**](PurchasableItemEndpointsApi.md#purchasableItemMutatePut) | **PUT** /purchasable-item/mutate | Mutate Purchasable Item
[**purchasableItemRemoveDelete**](PurchasableItemEndpointsApi.md#purchasableItemRemoveDelete) | **DELETE** /purchasable-item/remove | Remove Purchasable Item

<a name="purchasableItemCreatePost"></a>
# **purchasableItemCreatePost**
> SDPurchasableItemCreateResponse purchasableItemCreatePost(body)

Create Purchasable Item

Adds a new purchasable item

### Example
```javascript
import {SdPublicProdApi} from 'sd_public_prod_api';
let defaultClient = SdPublicProdApi.ApiClient.instance;

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

let apiInstance = new SdPublicProdApi.PurchasableItemEndpointsApi();
let body = new SdPublicProdApi.SDPurchasableItemCreateRequest(); // SDPurchasableItemCreateRequest | 

apiInstance.purchasableItemCreatePost(body, (error, data, response) => {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
});
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **body** | [**SDPurchasableItemCreateRequest**](SDPurchasableItemCreateRequest.md)|  | 

### Return type

[**SDPurchasableItemCreateResponse**](SDPurchasableItemCreateResponse.md)

### Authorization

[api_key](../README.md#api_key)

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: application/json

<a name="purchasableItemGetAllGet"></a>
# **purchasableItemGetAllGet**
> SDPurchasableItemGetAllResponses purchasableItemGetAllGet(purchasableId)

Get All Purchasable Items

Get the list of game purchasables

### Example
```javascript
import {SdPublicProdApi} from 'sd_public_prod_api';
let defaultClient = SdPublicProdApi.ApiClient.instance;

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

let apiInstance = new SdPublicProdApi.PurchasableItemEndpointsApi();
let purchasableId = "purchasableId_example"; // String | Purchasable ID Number (unsigned 32 bit integer)

apiInstance.purchasableItemGetAllGet(purchasableId, (error, data, response) => {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
});
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **purchasableId** | **String**| Purchasable ID Number (unsigned 32 bit integer) | 

### Return type

[**SDPurchasableItemGetAllResponses**](SDPurchasableItemGetAllResponses.md)

### Authorization

[api_key](../README.md#api_key)

### HTTP request headers

 - **Content-Type**: Not defined
 - **Accept**: application/json

<a name="purchasableItemGetGet"></a>
# **purchasableItemGetGet**
> SDPurchasableItemGetResponses purchasableItemGetGet(purchasableId, purchasableItemId)

Get Purchasable Item

Get A Purchasable Item from a Games Purchasable

### Example
```javascript
import {SdPublicProdApi} from 'sd_public_prod_api';
let defaultClient = SdPublicProdApi.ApiClient.instance;

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

let apiInstance = new SdPublicProdApi.PurchasableItemEndpointsApi();
let purchasableId = "purchasableId_example"; // String | Purchasable ID Number (unsigned 32 bit integer)
let purchasableItemId = "purchasableItemId_example"; // String | Purchasable Item ID Number (unsigned 32 bit integer)

apiInstance.purchasableItemGetGet(purchasableId, purchasableItemId, (error, data, response) => {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
});
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **purchasableId** | **String**| Purchasable ID Number (unsigned 32 bit integer) | 
 **purchasableItemId** | **String**| Purchasable Item ID Number (unsigned 32 bit integer) | 

### Return type

[**SDPurchasableItemGetResponses**](SDPurchasableItemGetResponses.md)

### Authorization

[api_key](../README.md#api_key)

### HTTP request headers

 - **Content-Type**: Not defined
 - **Accept**: application/json

<a name="purchasableItemMutatePut"></a>
# **purchasableItemMutatePut**
> Empty purchasableItemMutatePut(body)

Mutate Purchasable Item

Change a purchasable items data

### Example
```javascript
import {SdPublicProdApi} from 'sd_public_prod_api';
let defaultClient = SdPublicProdApi.ApiClient.instance;

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

let apiInstance = new SdPublicProdApi.PurchasableItemEndpointsApi();
let body = new SdPublicProdApi.SDPurchasableItemMutateRequest(); // SDPurchasableItemMutateRequest | 

apiInstance.purchasableItemMutatePut(body, (error, data, response) => {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
});
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **body** | [**SDPurchasableItemMutateRequest**](SDPurchasableItemMutateRequest.md)|  | 

### Return type

[**Empty**](Empty.md)

### Authorization

[api_key](../README.md#api_key)

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: application/json

<a name="purchasableItemRemoveDelete"></a>
# **purchasableItemRemoveDelete**
> Empty purchasableItemRemoveDelete(purchasableId, purchasableItemId)

Remove Purchasable Item

Delete (hide) a games Purchasable Item

### Example
```javascript
import {SdPublicProdApi} from 'sd_public_prod_api';
let defaultClient = SdPublicProdApi.ApiClient.instance;

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

let apiInstance = new SdPublicProdApi.PurchasableItemEndpointsApi();
let purchasableId = "purchasableId_example"; // String | Purchasable ID Number (unsigned 32 bit integer)
let purchasableItemId = "purchasableItemId_example"; // String | Purchasable Item ID Number (unsigned 32 bit integer)

apiInstance.purchasableItemRemoveDelete(purchasableId, purchasableItemId, (error, data, response) => {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
});
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **purchasableId** | **String**| Purchasable ID Number (unsigned 32 bit integer) | 
 **purchasableItemId** | **String**| Purchasable Item ID Number (unsigned 32 bit integer) | 

### Return type

[**Empty**](Empty.md)

### Authorization

[api_key](../README.md#api_key)

### HTTP request headers

 - **Content-Type**: Not defined
 - **Accept**: application/json

