---
title: Create
framework: driverkit
role: symbol
role_heading: Instance Method
path: driverkit/ioservice/create
---

# Create

Requests the creation of a new service object.

## Declaration

```occ
virtual kern_return_t Create(IOService *provider, const IOPropertyName propertiesKey, IOService **result);
```

## Parameters

- `provider`: The provider to associate with the new service object. Always specify the current service object as the provider.
- `propertiesKey`: The name of a property associated with the current service. The value of this property must be an doc://com.apple.driverkit/documentation/DriverKit/OSDictionary object, and the dictionary should contain the doc://com.apple.documentation/documentation/iokit/kioclasskey, doc://com.apple.documentation/documentation/iokit/kiouserclasskey, and doc://com.apple.documentation/documentation/iokit/kioservicedextentitlementskey matching keys.
- `result`: The service object for the newly created service. The class of this object is the one you specified using the doc://com.apple.documentation/documentation/iokit/kioclasskey in the propertiesKey dictionary This method retains the object, and you are responsible for releasing it.

## Return Value

Return Value kIOReturnSuccess on success, or another value if an error occurs. For a list of error codes, see Error Codes.

## Discussion

Discussion Call this method from your NewUserClient method when the system asks you to create a new service. The keys in the propertiesKey dictionary describe the new service. Use the kIOUserClassKey key to specify the name of the custom IOService subclass that you want the system to instantiate. Use the kIOClassKey to specify the name of the custom IOUserClient subclass to return to clients of your service. Use the kIOServiceDEXTEntitlementsKey key to specify an array of entitlement strings to match against the process of the new service. The new service must contain all of the requested entitlements.

## See Also

### Creating a New Service

- [NewUserClient](driverkit/ioservice/newuserclient.md)
