Add batch non eligible products
using System.Net.Http.Headers;var client = new HttpClient();var request = new HttpRequestMessage{ Method = HttpMethod.Post, RequestUri = new Uri("https://api.diller.app/api/v2.0/stores/your-store-id/non-eligible-products"), Headers = { { "Authorization", "Bearer <token>" }, }, Content = new StringContent("[ { \"product_id\": \"example\", \"product_id_prefix\": \"example\", \"product_category_id\": \"example\", \"description\": \"example\", \"subsystem\": \"example\", \"expires_at\": \"example\" } ]") { Headers = { ContentType = new MediaTypeHeaderValue("application/json") } }};using (var response = await client.SendAsync(request)){ response.EnsureSuccessStatusCode(); var body = await response.Content.ReadAsStringAsync(); Console.WriteLine(body);}package main
import ( "fmt" "strings" "net/http" "io")
func main() {
url := "https://api.diller.app/api/v2.0/stores/your-store-id/non-eligible-products"
payload := strings.NewReader("[ { \"product_id\": \"example\", \"product_id_prefix\": \"example\", \"product_category_id\": \"example\", \"description\": \"example\", \"subsystem\": \"example\", \"expires_at\": \"example\" } ]")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>") req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close() body, _ := io.ReadAll(res.Body)
fmt.Println(res) fmt.Println(string(body))
}OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json");RequestBody body = RequestBody.create(mediaType, "[ { \"product_id\": \"example\", \"product_id_prefix\": \"example\", \"product_category_id\": \"example\", \"description\": \"example\", \"subsystem\": \"example\", \"expires_at\": \"example\" } ]");Request request = new Request.Builder() .url("https://api.diller.app/api/v2.0/stores/your-store-id/non-eligible-products") .post(body) .addHeader("Authorization", "Bearer <token>") .addHeader("Content-Type", "application/json") .build();
Response response = client.newCall(request).execute();import axios from 'axios';
const options = { method: 'POST', url: 'https://api.diller.app/api/v2.0/stores/your-store-id/non-eligible-products', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, data: [ { product_id: 'example', product_id_prefix: 'example', product_category_id: 'example', description: 'example', subsystem: 'example', expires_at: 'example' } ]};
try { const { data } = await axios.request(options); console.log(data);} catch (error) { console.error(error);}const url = 'https://api.diller.app/api/v2.0/stores/your-store-id/non-eligible-products';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '[{"product_id":"example","product_id_prefix":"example","product_category_id":"example","description":"example","subsystem":"example","expires_at":"example"}]'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.diller.app/api/v2.0/stores/your-store-id/non-eligible-products \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '[ { "product_id": "example", "product_id_prefix": "example", "product_category_id": "example", "description": "example", "subsystem": "example", "expires_at": "example" } ]'Add a batch of non-eligible products for a specific store, with a maximum limit of 100 products.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”The unique identifier of the store.
Example
your-store-idRequest Body
Section titled “Request Body”The list of non-eligible products to add.
object
The external product id of the non eligible product
Prefix for filtering products with matching product IDs prefix.
The product category id that identifies all related products as non eligible
Options availabe are ‘All’ - It matchs all subsystems, ‘Loyalty’ - Regarding loyalty points subsystem, ‘Lipscore’
The date when the non-eligible product expires. It should use the format yyyy-MM-dd and be greater than today.
Examplegenerated
[ { "product_id": "example", "product_id_prefix": "example", "product_category_id": "example", "description": "example", "subsystem": "example", "expires_at": "example" }]object
The external product id of the non eligible product
Prefix for filtering products with matching product IDs prefix.
The product category id that identifies all related products as non eligible
Options availabe are ‘All’ - It matchs all subsystems, ‘Loyalty’ - Regarding loyalty points subsystem, ‘Lipscore’
The date when the non-eligible product expires. It should use the format yyyy-MM-dd and be greater than today.
Examplegenerated
[ { "product_id": "example", "product_id_prefix": "example", "product_category_id": "example", "description": "example", "subsystem": "example", "expires_at": "example" }]object
The external product id of the non eligible product
Prefix for filtering products with matching product IDs prefix.
The product category id that identifies all related products as non eligible
Options availabe are ‘All’ - It matchs all subsystems, ‘Loyalty’ - Regarding loyalty points subsystem, ‘Lipscore’
The date when the non-eligible product expires. It should use the format yyyy-MM-dd and be greater than today.
Examplegenerated
[ { "product_id": "example", "product_id_prefix": "example", "product_category_id": "example", "description": "example", "subsystem": "example", "expires_at": "example" }]Responses
Section titled “Responses”The non-eligible products were successfully added.
object
The external product id that is non eligible
Prefix for filtering products with matching product IDs.
The product category id that identifies all related products as non eligible
Examplegenerated
[ { "id": 1, "description": "example", "product_id": "example", "product_id_prefix": "example", "product_category_id": "example", "subsystem": "example", "expires_at": "example" }]Returns a BadRequest response if there are issues with the add request.
Issues may include validation failures.
Check the response body for details on the encountered errors.
object
Examplegenerated
[ { "product_id": "example", "product_id_prefix": "example", "errors": [ "example" ] }]