CY_BLE_CUSTOMC_CUSTOM_SERVICE_SERVICE_INDEX means the current number of custom service supported in GATT client. It cannot be defined as 0 if there is custom service existing.
CY_BLE_CUSTOMC_SERVICE_COUNT means the number of element in the cy_ble_customCServ array. It should be identical with CY_BLE_CUSTOMC_CUSTOM_SERVICE_SERVICE_INDEX.
Do you have an example project on how to use CY_BLE_CUSTOMC_CUSTOM_SERVICE_SERVICE_INDEX? From this other thread Democode for PSoC6 BLE central reading value from custom service , it is being used the same way I interpreted it, which is apparently wrong:
myVal.attrHandle = cy_ble_customCServ[CY_BLE_CUSTOMC_HEAT_COST_ALLOCATOR_SERVICE_SERVICE_INDEX].customServChar[CY_BLE_CUSTOMC_HEAT_COST_ALLOCATOR_SERVICE_SENSORDATA_CHAR_INDEX].customServCharHandle;
Seems no such code example for GATT server handles its custom service.
Can you please clarify more about the specific issue encountered?