> For the complete documentation index, see [llms.txt](https://edrus.gitbook.io/appgregator-api-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://edrus.gitbook.io/appgregator-api-docs/appgregators/payment-gateway/stripe/api/products/edit-product.md).

# Edit Product

<mark style="color:orange;">`PUT`</mark> `https://us-central1-appgregator.cloudfunctions.net/stripe/products/`

#### Query Parameters

| Name                                               | Type   | Description |
| -------------------------------------------------- | ------ | ----------- |
| name<mark style="color:red;">\*</mark>             | String | ft-4        |
| connection\_name<mark style="color:red;">\*</mark> | String | stripe-1    |

#### Headers

| Name                                        | Type   | Description |
| ------------------------------------------- | ------ | ----------- |
| x-api-key<mark style="color:red;">\*</mark> | String | XXX         |

#### Request Body

| Name   | Type    | Description |
| ------ | ------- | ----------- |
| active | Boolean | false       |

{% tabs %}
{% tab title="200: OK " %}

```javascript
{
    "id": "003",
    "object": "product",
    "active": false,
    "attributes": [],
    "created": 1675735411,
    "default_price": "price_1MYgWtIyq0PiFIhUAK9M3qbi",
    "description": "webinar",
    "images": [],
    "livemode": false,
    "metadata": {},
    "name": "webinar3",
    "package_dimensions": null,
    "shippable": null,
    "statement_descriptor": null,
    "tax_code": null,
    "type": "service",
    "unit_label": null,
    "updated": 1675824475,
    "url": null
}
```

{% endtab %}
{% endtabs %}

{% tabs %}
{% tab title="cURL" %}

```shell
curl --location --request PUT 'https://us-central1-appgregator.cloudfunctions.net/stripe/products/003?name=ft-4&connection_name=stripe-1' \
--header 'x-api-key: XXX' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'active=false'
```

{% endtab %}

{% tab title="NodeJS - Axios" %}

```javascript
var axios = require('axios');
var qs = require('qs');
var data = qs.stringify({
  'active': 'false' 
});
var config = {
  method: 'put',
  url: 'https://us-central1-appgregator.cloudfunctions.net/stripe/products/003?name=ft-4&connection_name=stripe-1',
  headers: { 
    'x-api-key': 'XXX', 
    'Content-Type': 'application/x-www-form-urlencoded'
  },
  data : data
};

axios(config)
.then(function (response) {
  console.log(JSON.stringify(response.data));
})
.catch(function (error) {
  console.log(error);
});

```

{% endtab %}

{% tab title="PHP - cURL" %}

```php
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://us-central1-appgregator.cloudfunctions.net/stripe/products/003?name=ft-4&connection_name=stripe-1',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'PUT',
  CURLOPT_POSTFIELDS => 'active=false',
  CURLOPT_HTTPHEADER => array(
    'x-api-key: XXX',
    'Content-Type: application/x-www-form-urlencoded'
  ),
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;

```

{% endtab %}
{% endtabs %}
