<!--
{
  "availability" : [
    "iOS: 15.0.0 -",
    "iPadOS: 15.0.0 -",
    "macCatalyst: 15.0.0 -",
    "macOS: 12.0.0 -",
    "tvOS: 15.0.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 8.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Network",
  "identifier" : "/documentation/Network/nw_parameters_set_attribution(_:_:)",
  "metadataVersion" : "0.1.0",
  "role" : "Function",
  "symbol" : {
    "kind" : "Function",
    "modules" : [
      "Network"
    ],
    "preciseIdentifier" : "c:@F@nw_parameters_set_attribution"
  },
  "title" : "nw_parameters_set_attribution(_:_:)"
}
-->

# nw_parameters_set_attribution(_:_:)

Sets a flag that indicates whether the network request originates from the developer or the user.

```
func nw_parameters_set_attribution(_ parameters: nw_parameters_t, _ attribution: nw_parameters_attribution_t)
```

## Parameters

`parameters`

The network parameters to update.

`attribution`

An indication of whether the network request comes from the developer or from the user.

## Discussion

If you don’t set this flag, the system assumes a value of [`nw_parameters_attribution_t.developer`](/documentation/Network/nw_parameters_attribution_t/developer). Use this default value for any network request that your app makes that isn’t explicitly from the user. This includes requests that you make to your own server, even when you load user data. It also includes links that the user selects, but that you modify in any way — including by adding HTTP headers — before loading the content.

Set this value to [`nw_parameters_attribution_t.user`](/documentation/Network/nw_parameters_attribution_t/user) only for requests that the user explicitly makes, like when the user enters a URL or taps or clicks a URL that they can read, and only if your app loads and displays the data without altering the request.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)