nrf connect sdk - generic discovery and reading/writing Gatt services and characteristics

I would like to use the nrf connect sdk to connect to a device and 'discover' the GATT services it supports, the characteristics in each service, and then read the descriptions/values for each characteristic.

I would prefer the software to have no knowledge of the target Peripheral.

I would then like to update (write) some of the the characteristic values.

Do you have any samples or guidance on how the GATT discovery/read/write can be achieved? The samples I have seen appear to 'ask the peripheral' if they support a particular service/uuid.

Related