A cap, especially a disinfectant cap, is for protecting and/or closing off the abdominal connector used in peritoneal dialysis, and to a detection device for peritoneal dialysis. There is a bag set for peritoneal dialysis and use thereof. In view of the sometimes serious consequences of an incorrect sequence of fluids in the patient's abdominal cavity, it is desirable to prevent an incorrect sequence of fluids during peritoneal dialysis. This is achieved by providing the cap, especially a disinfectant cap, with information about the medium contained at any one time in the patient's abdominal cavity. In this way it is always possible—even after the fluid has been dispensed into the abdominal cavity and the bag disposed of—to determine which medium is currently in the patient's abdominal cavity and/or to record other details, such as the amount, the concentration, the manufacturer, etc. of the medium, and to take this information into account, especially during subsequent stages of the peritoneal dialysis treatment.