---
title: "session(_:didStartReceivingResourceWithName:fromPeer:with:)"
framework: multipeerconnectivity
role: symbol
role_heading: Instance Method
path: "multipeerconnectivity/mcsessiondelegate/session(_:didstartreceivingresourcewithname:frompeer:with:)"
---

# session(_:didStartReceivingResourceWithName:fromPeer:with:)

Indicates that the local peer began receiving a resource from a nearby peer.

## Declaration

```swift
func session(_ session: MCSession, didStartReceivingResourceWithName resourceName: String, fromPeer peerID: MCPeerID, with progress: Progress)
```

## Parameters

- `session`: The session that started receiving the resource.
- `resourceName`: The name of the resource, as provided by the sender.
- `peerID`: The sender’s peer ID.
- `progress`: An NSProgress object that can be used to cancel the transfer or queried to determine how far the transfer has progressed.

## See Also

### MCSession Delegate Methods

- [session(_:didReceive:fromPeer:)](multipeerconnectivity/mcsessiondelegate/session(_:didreceive:frompeer:).md)
- [session(_:didFinishReceivingResourceWithName:fromPeer:at:withError:)](multipeerconnectivity/mcsessiondelegate/session(_:didfinishreceivingresourcewithname:frompeer:at:witherror:).md)
- [session(_:didReceive:withName:fromPeer:)](multipeerconnectivity/mcsessiondelegate/session(_:didreceive:withname:frompeer:).md)
- [session(_:peer:didChange:)](multipeerconnectivity/mcsessiondelegate/session(_:peer:didchange:).md)
- [session(_:didReceiveCertificate:fromPeer:certificateHandler:)](multipeerconnectivity/mcsessiondelegate/session(_:didreceivecertificate:frompeer:certificatehandler:).md)
