This documentation is currently under development. Certain sections are not yet complete and will be added shortly.
For the complete documentation index, see llms.txt. This page is also available as Markdown.

Cegid

Read a Y2 receipt

get
/api/{tenantId}/admin/extensions/cegid/y2/sandbox

Returns a summary of the receipt: items (one { label, quantity, price } per line, the price being the tax-included unit price), date, customerId (the Y2 customer id), currencyId and total (tax included), amounts as Y2 holds them.

Path parameters
tenantIdstringRequired
Query parameters
keystringOptional

Y2 key of the receipt, as {stump}-{number}, e.g. ST202-1409. The number is the digits after the last -; anything else is refused with 400.

Pattern: (?<Stump>.*)-(?<Number>\d+)
externalReferencestringOptional

External reference of the receipt in Y2; 404 when no receipt has it.

Responses
200

Receipt returned.

anyOptional
get/api/{tenantId}/admin/extensions/cegid/y2/sandbox
GET /api/{tenantId}/admin/extensions/cegid/y2/sandbox HTTP/1.1
Host: app.neostore.cloud
Accept: */*

No content

Attach a Y2 receipt to a customer

post
/api/{tenantId}/admin/extensions/cegid/y2/sandbox/attachReceiptToCustomer

Finds the Y2 customer with the email, or creates one, then sets that customer on the receipt in Y2, through the default Y2 connection. A created customer gets firstName and lastName from the body; when absent, they are derived from the part of the email before @: jane.doe@… gives jane and doe, a part without a dot is used for both.

Required scopes
This endpoint requires the following scopes:
Authorizations
OAuth2implicitRequired
Authorization URL:
Path parameters
tenantIdstringRequired
Query parameters
keystringOptional

Y2 key of the receipt, as {stump}-{number}, e.g. ST202-1409. The number is the digits after the last -; anything else is refused with 400.

Pattern: (?<Stump>.*)-(?<Number>\d+)
externalReferencestringOptional

External reference of the receipt in Y2; 404 when no receipt has it.

Body
anyOptional
Responses
200

Customer found or created and attached to the receipt.

stringOptional
post/api/{tenantId}/admin/extensions/cegid/y2/sandbox/attachReceiptToCustomer
POST /api/{tenantId}/admin/extensions/cegid/y2/sandbox/attachReceiptToCustomer HTTP/1.1
Host: app.neostore.cloud
Authorization: Bearer YOUR_OAUTH2_TOKEN
Content-Type: application/json
Accept: */*
text

List Cegid civilities (titles)

get
/api/{tenantId}/admin/extensions/cegid/y2/settings/civilities

The civilities defined in Y2, as Y2 returns them. A customer's title is sent to Y2 as a civility id.

Required scopes
This endpoint requires the following scopes:
Authorizations
OAuth2implicitRequired
Authorization URL:
Path parameters
tenantIdstringRequired
Responses
200

Civilities returned.

No content

get/api/{tenantId}/admin/extensions/cegid/y2/settings/civilities
GET /api/{tenantId}/admin/extensions/cegid/y2/settings/civilities HTTP/1.1
Host: app.neostore.cloud
Authorization: Bearer YOUR_OAUTH2_TOKEN
Accept: */*

No content

List Cegid countries and regions

get
/api/{tenantId}/admin/extensions/cegid/y2/settings/countries

One entry per Y2 country, carrying id, languageId, shortDescription, description, currencyId, nationality, isoCode (isO3NumCode, isO2AlphaNumCode, isO3AlphaNumCode; null when Y2 has none) and regions, the Y2 regions whose countryId is the country's id. A customer's country is sent to Y2 as the ISO alpha-2 code.

Required scopes
This endpoint requires the following scopes:
Authorizations
OAuth2implicitRequired
Authorization URL:
Path parameters
tenantIdstringRequired
Responses
200

Countries and regions returned.

No content

get/api/{tenantId}/admin/extensions/cegid/y2/settings/countries
GET /api/{tenantId}/admin/extensions/cegid/y2/settings/countries HTTP/1.1
Host: app.neostore.cloud
Authorization: Bearer YOUR_OAUTH2_TOKEN
Accept: */*

No content

Verify country ISO code uniqueness

get
/api/{tenantId}/admin/extensions/cegid/y2/settings/countries/test

Finds the ISO alpha-2 codes shared by several Y2 countries. Customers' countries are sent to Y2 as ISO alpha-2 codes, so such a code is ambiguous for Y2. Only the alpha-2 code is checked; countries without one are left out.

The body is { "duplicatedCountries": { "simpleData": [...], "fullData": [...] } }: simpleData holds one { iso2, values: [{ id, shortDescription }] } per shared code, and fullData one array of complete Y2 countries per shared code, in the same order. Both are empty when every code is unique.

Required scopes
This endpoint requires the following scopes:
Authorizations
OAuth2implicitRequired
Authorization URL:
Path parameters
tenantIdstringRequired
Responses
200

Report returned, possibly empty.

No content

get/api/{tenantId}/admin/extensions/cegid/y2/settings/countries/test
GET /api/{tenantId}/admin/extensions/cegid/y2/settings/countries/test HTTP/1.1
Host: app.neostore.cloud
Authorization: Bearer YOUR_OAUTH2_TOKEN
Accept: */*

No content

List Cegid supported languages

get
/api/{tenantId}/admin/extensions/cegid/y2/settings/languages

The languages defined in Y2, as Y2 returns them.

Required scopes
This endpoint requires the following scopes:
Authorizations
OAuth2implicitRequired
Authorization URL:
Path parameters
tenantIdstringRequired
Responses
200

Languages returned.

No content

get/api/{tenantId}/admin/extensions/cegid/y2/settings/languages
GET /api/{tenantId}/admin/extensions/cegid/y2/settings/languages HTTP/1.1
Host: app.neostore.cloud
Authorization: Bearer YOUR_OAUTH2_TOKEN
Accept: */*

No content

List all Cegid Y2 stores

get
/api/{tenantId}/admin/extensions/cegid/y2/stores

Returns every Y2 store as Y2 sends it, unpaged and unfiltered.

Required scopes
This endpoint requires the following scopes:
Authorizations
OAuth2implicitRequired
Authorization URL:
Path parameters
tenantIdstringRequired
Responses
200

Stores returned.

No content

get/api/{tenantId}/admin/extensions/cegid/y2/stores
GET /api/{tenantId}/admin/extensions/cegid/y2/stores HTTP/1.1
Host: app.neostore.cloud
Authorization: Bearer YOUR_OAUTH2_TOKEN
Accept: */*

No content

Open the customer form for a LiveStore session

get
/api/{tenantId}/external/livestore

Where LiveStore sends the associate's browser. Redirects to the tenant's LiveStore customer form, opened for the session's customer, passing on every other query parameter. In tablet mode, the form opens in tablet mode.

A storeId value of the form 530?sessionId=xxx is read as storeId=530 and sessionId=xxx.

Path parameters
tenantIdstringRequired
Query parameters
Responses
204

No sessionId was sent (connection check); nothing is done.

No content

get/api/{tenantId}/external/livestore
GET /api/{tenantId}/external/livestore HTTP/1.1
Host: app.neostore.cloud
Accept: */*

No content

Check the connection

get
/api/{tenantId}/external/livestore/session

Lets LiveStore check, with GET or HEAD, that the session endpoint is reachable. Has no effect.

Path parameters
tenantIdstringRequired
Responses
204

The endpoint is reachable.

No content

get/api/{tenantId}/external/livestore/session
GET /api/{tenantId}/external/livestore/session HTTP/1.1
Host: app.neostore.cloud
Accept: */*

No content

Open a LiveStore session for a customer

post
/api/{tenantId}/external/livestore/session

Called by Cegid LiveStore before it sends the associate to the form. The session is valid for one hour from this call; posting again under the same sessionId replaces the customer and restarts the hour. An expired session no longer opens the form.

Required scopes
This endpoint requires the following scopes:
Authorizations
OAuth2implicitRequired
Authorization URL:
Path parameters
tenantIdstringRequired
Query parameters
sessionIdstringOptional

Identifier LiveStore chose for the session; the form is later opened with it. Required.

storeIdstringOptional

Store the session is opened in. When sent, replaces storeId of the body.

Body

The customer a Cegid LiveStore session is opened for.

callbackUrlstringRequired

Base URL of the LiveStore instance that opened the session. Once the holder's account is saved, the form redirects to {callbackUrl}/customers/{customerId}.

customerIdstring · nullableOptional

Identifier of the customer in the retail system LiveStore works with (Y2 or UR, per the tenant's LiveStore configuration). Set on the account as id.y2.customerId or id.ur.customerId; when absent, the account gets no customer identifier from the session.

storeIdstring · nullableOptional

Store the session is opened in. The storeId query parameter, when sent, replaces it.

Other propertiesanyOptional
Responses
200

Session stored.

No content

post/api/{tenantId}/external/livestore/session
POST /api/{tenantId}/external/livestore/session HTTP/1.1
Host: app.neostore.cloud
Authorization: Bearer YOUR_OAUTH2_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 92

{
  "callbackUrl": "text",
  "customerId": null,
  "storeId": null,
  "ANY_ADDITIONAL_PROPERTY": "anything"
}

No content

Check the connection

head
/api/{tenantId}/external/livestore/session

Lets LiveStore check, with GET or HEAD, that the session endpoint is reachable. Has no effect.

Path parameters
tenantIdstringRequired
Responses
204

The endpoint is reachable.

No content

head/api/{tenantId}/external/livestore/session
HEAD /api/{tenantId}/external/livestore/session HTTP/1.1
Host: app.neostore.cloud
Accept: */*

No content

List the Y2 business notification subscriptions

get
/api/{tenantId}/webhooks/listeners/cegid/{connectionId}

Returns every subscription Y2 reports as active for the connection's database, this platform's own included, to check where Y2 sends its notifications.

Required scopes
This endpoint requires the following scopes:
Authorizations
OAuth2implicitRequired
Authorization URL:
Path parameters
connectionIdstringRequired

name of the Y2 connection whose database is read.

tenantIdstringRequired
Responses
200

Subscriptions returned, possibly none.

A Y2 business notification subscription: where Y2 sends its notifications for a database, and which ones.

enabledbooleanOptional

Whether Y2 currently delivers to this subscription. Registering this platform's subscription disables another enabled one.

idstringRequired

Y2 identifier of the subscription.

namestringRequired

Name of the subscription in Y2.

urlstringRequired

URL Y2 posts the notifications to. For this platform's subscription, it ends with /api/{tenantId}/webhooks/listeners/cegid/{connection name}.

get/api/{tenantId}/webhooks/listeners/cegid/{connectionId}
GET /api/{tenantId}/webhooks/listeners/cegid/{connectionId} HTTP/1.1
Host: app.neostore.cloud
Authorization: Bearer YOUR_OAUTH2_TOKEN
Accept: */*
[
  {
    "enabled": true,
    "id": "text",
    "name": "text",
    "url": "text",
    "headers": {
      "ANY_ADDITIONAL_PROPERTY": "text"
    },
    "user": {
      "userName": null
    },
    "filters": [
      {
        "eventSources": [
          "text"
        ],
        "userIds": [
          "text"
        ],
        "action": 0
      }
    ]
  }
]

Process Cegid Y2 business notifications

post
/api/{tenantId}/webhooks/listeners/cegid/{connectionId}

Called by Y2. Header.EventSource decides the handling; each recognised notification is re-emitted as a platform event: …ThirdParties.Customers.ICustomerService.Create: Y2:BusinessNotification:CustomerCreated; passes are not updated.…ThirdParties.Customers.ICustomerService.Update: Y2:BusinessNotification:CustomerUpdated; the passes whose y2.customerId identifier is Body.Key.CustomerId are updated.…ISaleAndSellersService.CreateReceipt, …Engine.RegisterSale, …Documents.Sales.ISaleService.Create and …ManagementService.CreateFrom: Y2:BusinessNotification:ReceiptCreated; the passes of the sale document's customer are updated. A receipt on hold updates no pass. Body.Key may be wrapped in a second Key.…ILoyaltyEngineService.AddCardOperations: Y2:BusinessNotification:LoyaltyUpdated; the passes of the card's customer are updated.Any other source: Y2:BusinessNotification:Generic, with the body untouched. Body properties are matched case-insensitively.

Required scopes
This endpoint requires the following scopes:
Authorizations
OAuth2implicitRequired
Authorization URL:
Path parameters
connectionIdstringRequired

name of the Y2 connection the subscription was registered for.

tenantIdstringRequired
Body

A Y2 business notification: what happened, and the key of the entity it happened to.

__idstringOptional

See . A new GUID when the event is raised.

__creationDateone ofOptional

See . The current UTC time when the event is raised. Accepts ISO 8601 date-time string or Unix epoch seconds in request inputs. Responses are serialized as ISO 8601 date-time strings.

string · date-timeOptional
or
integer · int64Optional
__eventNamestringOptional
BodyanyRequired

Key of the entity the notification is about, under Key. Its shape depends on Header.EventSource.

Responses
200

Notification accepted and its event emitted.

No content

post/api/{tenantId}/webhooks/listeners/cegid/{connectionId}
POST /api/{tenantId}/webhooks/listeners/cegid/{connectionId} HTTP/1.1
Host: app.neostore.cloud
Authorization: Bearer YOUR_OAUTH2_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 230

{
  "__id": "text",
  "__creationDate": "2026-01-01T00:00:00.000Z",
  "__eventName": "text",
  "Header": {
    "EventId": "text",
    "EventSource": "text",
    "ContentType": "text",
    "SourceId": "text",
    "UserId": "text",
    "Date": "2026-01-01T00:00:00.000Z"
  },
  "Body": null
}

No content

Register the Y2 business notification subscription

post
/api/{tenantId}/webhooks/listeners/cegid/{connectionId}/Register

Makes Y2 push its business notifications for the connection's database to this platform. As Y2 delivers to a single subscription, another enabled subscription on that database is disabled. This platform's subscription is created or updated to call …/webhooks/listeners/cegid/{connectionId}. Saving the Cegid Y2 configuration does the same for every connection with listenToBusinessNotification.

Required scopes
This endpoint requires the following scopes:
Authorizations
OAuth2implicitRequired
Authorization URL:
Path parameters
connectionIdstringRequired

name of the Y2 connection to register the subscription for.

tenantIdstringRequired
Responses
200

Subscription registered.

No content

post/api/{tenantId}/webhooks/listeners/cegid/{connectionId}/Register
POST /api/{tenantId}/webhooks/listeners/cegid/{connectionId}/Register HTTP/1.1
Host: app.neostore.cloud
Authorization: Bearer YOUR_OAUTH2_TOKEN
Accept: */*

No content

Last updated