Retrieves all store's segments
GET
/api/v2.0/stores/{storeId}/segments
using System.Net.Http.Headers;var client = new HttpClient();var request = new HttpRequestMessage{ Method = HttpMethod.Get, RequestUri = new Uri("https://api.diller.app/api/v2.0/stores/your-store-id/segments"), Headers = { { "Authorization", "Bearer <token>" }, },};using (var response = await client.SendAsync(request)){ response.EnsureSuccessStatusCode(); var body = await response.Content.ReadAsStringAsync(); Console.WriteLine(body);}package main
import ( "fmt" "net/http" "io")
func main() {
url := "https://api.diller.app/api/v2.0/stores/your-store-id/segments"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
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();
Request request = new Request.Builder() .url("https://api.diller.app/api/v2.0/stores/your-store-id/segments") .get() .addHeader("Authorization", "Bearer <token>") .build();
Response response = client.newCall(request).execute();import axios from 'axios';
const options = { method: 'GET', url: 'https://api.diller.app/api/v2.0/stores/your-store-id/segments', headers: {Authorization: 'Bearer <token>'}};
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/segments';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://api.diller.app/api/v2.0/stores/your-store-id/segments \ --header 'Authorization: Bearer <token>'Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”storeId
required
string
The Id of the store
Example
your-store-idResponses
Section titled “Responses”OK
Media typeapplication/json
Array<object>
object
id
integer format: int32
text
string
type
required
string
is_visible_to_follower
boolean
is_required
boolean
options
Array<object>
object
id
integer format: int32
text
string
Example
[ { "type": "Text" }]Bad Request
Media typeapplication/json
object
type
string
title
string
status
integer format: int32
detail
string
instance
string
errors
object
key
additional properties
Array<string>
key
additional properties
Examplegenerated
{ "type": "example", "title": "example", "status": 1, "detail": "example", "instance": "example", "errors": { "additionalProperty": [ "example" ] }}