Skip to content

Commit

Permalink
chore: update GitHub branch references to use HEAD (#1032)
Browse files Browse the repository at this point in the history
  • Loading branch information
thinkingserious authored Aug 5, 2020
1 parent 4796a9c commit 7b399a0
Show file tree
Hide file tree
Showing 10 changed files with 44 additions and 44 deletions.
8 changes: 4 additions & 4 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -241,13 +241,13 @@ All notable changes to this project will be documented in this file.
## Added
- #509 Transient Fault Handling (dependency free)
- Implements retry behaviour for transient faults when using HttpClient to send the request.
- Please see #509 and [USE_CASES.md](https://github.com/sendgrid/sendgrid-csharp/blob/master/USE_CASES.md#transient_faults) for details.
- Please see #509 and [USE_CASES.md](USE_CASES.md#transient_faults) for details.
- Thanks to [Dylan Morley](https://github.com/dylan-asos) for the PR!

## [9.8.0] - 2017-08-15
## Added
- Single email to multiple recipients - Toggle display of recipients #508
- The method `CreateSingleEmailToMultipleRecipients` now has an additional optional parameter to control whether the email recipients can see each others email addresses. Please see [USE_CASES.md](https://github.com/sendgrid/sendgrid-csharp/blob/master/USE_CASES.md#singleemailmultiplerecipients) for details.
- The method `CreateSingleEmailToMultipleRecipients` now has an additional optional parameter to control whether the email recipients can see each others email addresses. Please see [USE_CASES.md](USE_CASES.md#singleemailmultiplerecipients) for details.
- Thanks to [Niladri Dutta](Niladri24dutta) for the PR!

## [9.7.0] - 2017-08-03
Expand Down Expand Up @@ -350,7 +350,7 @@ All notable changes to this project will be documented in this file.
## [8.0.4] - 2016-08-24 ##
### Added
- Table of Contents in the README
- Added a [USE_CASES.md](https://github.com/sendgrid/sendgrid-csharp/blob/master/USE_CASES.md) section, with the first use case example for transactional templates
- Added a [USE_CASES.md](USE_CASES.md) section, with the first use case example for transactional templates

## [8.0.3] - 2016-08-17 ##
## Fixed
Expand All @@ -365,7 +365,7 @@ All notable changes to this project will be documented in this file.

## [8.0.1] - 2016-07-25 ##
### Added
- [Troubleshooting](https://github.com/sendgrid/sendgrid-csharp/blob/master/TROUBLESHOOTING.md) section
- [Troubleshooting](TROUBLESHOOTING.md) section

## [8.0.0] - 2016-07-22 ##
## BREAKING CHANGE
Expand Down
18 changes: 9 additions & 9 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,27 +77,27 @@ Next, update your Environment with your [SENDGRID_APIKEY](https://app.sendgrid.c
##### Execute: #####

- Check out the documentation for [Web API v3 endpoints](https://sendgrid.com/docs/API_Reference/Web_API_v3/index.html).
- Review the corresponding [examples](https://github.com/sendgrid/sendgrid-csharp/blob/master/examples).
- You can add your test code to our [Example Project](https://github.com/sendgrid/sendgrid-csharp/blob/master/ExampleCoreProject/Example.cs).
- Review the corresponding [examples](examples).
- You can add your test code to our [Example Project](ExampleCoreProject/Program.cs).

<a name="understanding-the-codebase"></a>
## Understanding the Code Base

- **[/examples](https://github.com/sendgrid/sendgrid-csharp/blob/master/examples)**
- **[/examples](examples)**
- Examples that demonstrate usage.
- **[/ExampleCoreProject/Example.cs](https://github.com/sendgrid/sendgrid-csharp/blob/master/ExampleCoreProject/Example.cs)**
- **[/ExampleCoreProject/Program.cs](ExampleCoreProject/Program.cs)**
- A working .NET Core example project for testing.
- **[/ExampleNet45Project/Example.cs](https://github.com/sendgrid/sendgrid-csharp/blob/master/ExampleNet45Project/Example.cs)**
- **[/ExampleNet45Project/Program.cs](ExampleNet45Project/Program.cs)**
- A working .NET 4.5.2 example project for testing.
- **[/src/SendGrid/SendGridClient.cs](https://github.com/sendgrid/sendgrid-csharp/blob/master/src/SendGrid/SendGridClient.cs)**
- **[/src/SendGrid/SendGridClient.cs](src/SendGrid/SendGridClient.cs)**
- The main interface to the Twilio SendGrid API is the class `SendGridClient`.
- **[/tests/SendGrid.Tests/Integration.cs](https://github.com/sendgrid/sendgrid-csharp/blob/master/tests/SendGrid.Tests/Integration.cs)**
- **[/tests/SendGrid.Tests/Integration.cs](tests/SendGrid.Tests/Integration.cs)**
- Integration tests

<a name="testing"></a>
## Testing

All PRs require passing tests before the PR will be reviewed. All test files are in the [`SendGrid.Tests`](https://github.com/sendgrid/sendgrid-csharp/blob/master/tests/SendGrid.Tests) directory. For the purposes of contributing to this repo, please update the [`Integration.cs`](https://github.com/sendgrid/sendgrid-csharp/blob/master/tests/SendGrid.Tests/Integration.cs) file with unit tests as you modify the code.
All PRs require passing tests before the PR will be reviewed. All test files are in the [`SendGrid.Tests`](tests/SendGrid.Tests) directory. For the purposes of contributing to this repo, please update the [`Integration.cs`](tests/SendGrid.Tests/Integration.cs) file with unit tests as you modify the code.

The integration tests require a Twilio SendGrid mock API in order to execute. We've simplified setting this up using Docker to run the tests. You will just need [Docker Desktop](https://docs.docker.com/get-docker/) and `make`.

Expand All @@ -106,7 +106,7 @@ Once these are available, simply execute the Docker test target to run all tests
<a name="style-guidelines-and-naming-conventions"></a>
## Style Guidelines & Naming Conventions

Generally, we follow the style guidelines as suggested by the official language. However, we ask that you conform to the styles that already exist in the library. If you wish to deviate, please explain your reasoning. In this case, we generally follow the [C# Naming Conventions](https://msdn.microsoft.com/library/ms229045(v=vs.100).aspx), the suggestions provided by the Visual Studio IDE and StyleCop (see the [stylecop.json](https://github.com/sendgrid/sendgrid-csharp/blob/master/src/SendGrid/stylecop.json) and [SendGrid.ruleset](https://github.com/sendgrid/sendgrid-csharp/blob/master/src/SendGrid/SendGrid.ruleset) configuration files.
Generally, we follow the style guidelines as suggested by the official language. However, we ask that you conform to the styles that already exist in the library. If you wish to deviate, please explain your reasoning. In this case, we generally follow the [C# Naming Conventions](https://msdn.microsoft.com/library/ms229045(v=vs.100).aspx), the suggestions provided by the Visual Studio IDE and StyleCop (see the [stylecop.json](src/SendGrid/stylecop.json) and [SendGrid.ruleset](src/SendGrid/SendGrid.ruleset) configuration files.

<a name="creating-a-pull-request"></a>
## Creating a Pull Request
Expand Down
38 changes: 19 additions & 19 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
![SendGrid Logo](https://github.com/sendgrid/sendgrid-python/raw/master/twilio_sendgrid_logo.png)
![SendGrid Logo](twilio_sendgrid_logo.png)

[![BuildStatus](https://travis-ci.org/sendgrid/sendgrid-csharp.png?branch=master)](https://travis-ci.org/sendgrid/sendgrid-csharp)
[![BuildStatus](https://travis-ci.org/sendgrid/sendgrid-csharp.png?branch=main)](https://travis-ci.org/sendgrid/sendgrid-csharp)
[![NuGet](https://img.shields.io/nuget/v/SendGrid.svg)](https://www.nuget.org/packages/SendGrid)
[![Email Notifications Badge](https://dx.sendgrid.com/badge/csharp)](https://dx.sendgrid.com/newsletter/csharp)
[![MIT licensed](https://img.shields.io/badge/license-MIT-blue.svg)](./LICENSE.md)
Expand All @@ -12,17 +12,17 @@
**The default branch name for this repository has been changed to `main` as of 07/27/2020.**

* Subscribe to email [notifications](https://dx.sendgrid.com/newsletter/csharp) for releases and breaking changes.
* Send SMS messages with [Twilio](https://github.com/sendgrid/sendgrid-csharp/blob/master/USE_CASES.md#sms).
* Send SMS messages with [Twilio](USE_CASES.md#sms).

# Overview

**This library allows you to quickly and easily use the Twilio SendGrid Web API v3 via C# with .NET.**

Version 9.X.X+ of this library provides full support for all Twilio SendGrid [Web API v3](https://sendgrid.com/docs/API_Reference/api_v3.html) endpoints, including the new [v3 /mail/send](https://sendgrid.com/blog/introducing-v3mailsend-sendgrids-new-mail-endpoint).

We want this library to be community driven, and Twilio SendGrid led. We need your help to realize this goal. To help make sure we are building the right things in the right order, we ask that you create [issues](https://github.com/sendgrid/sendgrid-csharp/issues) and [pull requests](https://github.com/sendgrid/sendgrid-csharp/blob/master/CONTRIBUTING.md) or simply upvote or comment on existing issues or pull requests.
We want this library to be community driven, and Twilio SendGrid led. We need your help to realize this goal. To help make sure we are building the right things in the right order, we ask that you create [issues](https://github.com/sendgrid/sendgrid-csharp/issues) and [pull requests](CONTRIBUTING.md) or simply upvote or comment on existing issues or pull requests.

For updates to this library, see our [CHANGELOG](https://github.com/sendgrid/sendgrid-csharp/blob/master/CHANGELOG.md) and [releases](https://github.com/sendgrid/sendgrid-csharp/releases).
For updates to this library, see our [CHANGELOG](CHANGELOG.md) and [releases](https://github.com/sendgrid/sendgrid-csharp/releases).

Subscribe to email [release notifications](https://dx.sendgrid.com/newsletter/csharp) to receive emails about releases and breaking changes.

Expand Down Expand Up @@ -104,11 +104,11 @@ dotnet add package SendGrid.Extensions.DependencyInjection
```

Once you have the Twilio SendGrid library installed, you can include calls to it in your code.
For sample implementations, see the [.NET Core Example](https://github.com/sendgrid/sendgrid-csharp/tree/master/ExampleCoreProject) and the [.NET 4.5.2 Example](https://github.com/sendgrid/sendgrid-csharp/tree/master/ExampleNet45Project) folders.
For sample implementations, see the [.NET Core Example](ExampleCoreProject) and the [.NET 4.5.2 Example](ExampleNet45Project) folders.

## Dependencies

Please see the [.csproj file](https://github.com/sendgrid/sendgrid-csharp/blob/master/src/SendGrid/SendGrid.csproj).
Please see the [.csproj file](src/SendGrid/SendGrid.csproj).

# Quick Start

Expand Down Expand Up @@ -169,7 +169,7 @@ class Program
}
```

You can find an example of all the email features [here](https://github.com/sendgrid/sendgrid-csharp/blob/master/tests/SendGrid.Tests/Integration.cs#L79).
You can find an example of all the email features [here](tests/SendGrid.Tests/Integration.cs#L79).

<a name="v3"></a>
## General v3 Web API Usage
Expand Down Expand Up @@ -244,34 +244,34 @@ class Program
# Usage

- [Twilio SendGrid Docs](https://sendgrid.com/docs/API_Reference/api_v3.html)
- [Library Usage Docs](https://github.com/sendgrid/sendgrid-csharp/tree/master/USAGE.md)
- [Example Code - .NET Core](https://github.com/sendgrid/sendgrid-csharp/tree/master/ExampleCoreProject)
- [Example Code - .NET 4.5.2+](https://github.com/sendgrid/sendgrid-csharp/tree/master/ExampleNet45Project)
- [Library Usage Docs](USAGE.md)
- [Example Code - .NET Core](ExampleCoreProject)
- [Example Code - .NET 4.5.2+](ExampleNet45Project)
- [How-to: Migration from v2 to v3](https://sendgrid.com/docs/Classroom/Send/v3_Mail_Send/how_to_migrate_from_v2_to_v3_mail_send.html)
- [v3 Web API Mail Send Helper](https://github.com/sendgrid/sendgrid-csharp/tree/master/src/SendGrid/Helpers/Mail)
- [v3 Web API Mail Send Helper](src/SendGrid/Helpers/Mail)

# Use Cases

Here are some [examples of common API use cases](https://github.com/sendgrid/sendgrid-csharp/blob/master/USE_CASES.md), such as how to send an email with a transactional template.
Here are some [examples of common API use cases](USE_CASES.md), such as how to send an email with a transactional template.

# Roadmap

If you are interested in the future direction of this project, please take a look at our open [issues](https://github.com/sendgrid/sendgrid-csharp/issues) and [pull requests](https://github.com/sendgrid/sendgrid-csharp/pulls). We would love to hear your feedback!

# How to Contribute

We encourage contribution to our library (you might even score some nifty swag), please see our [CONTRIBUTING](https://github.com/sendgrid/sendgrid-csharp/tree/master/CONTRIBUTING.md) guide for details.
We encourage contribution to our library (you might even score some nifty swag), please see our [CONTRIBUTING](CONTRIBUTING.md) guide for details.

Quick links:

- [Feature Request](https://github.com/sendgrid/sendgrid-csharp/tree/master/CONTRIBUTING.md#feature-request)
- [Bug Reports](https://github.com/sendgrid/sendgrid-csharp/tree/master/CONTRIBUTING.md#submit-a-bug-report)
- [Improvements to the Codebase](https://github.com/sendgrid/sendgrid-csharp/tree/master/CONTRIBUTING.md#improvements-to-the-codebase)
- [Review Pull Requests](https://github.com/sendgrid/sendgrid-csharp/tree/master/CONTRIBUTING.md#code-reviews)
- [Feature Request](CONTRIBUTING.md#feature-request)
- [Bug Reports](CONTRIBUTING.md#submit-a-bug-report)
- [Improvements to the Codebase](CONTRIBUTING.md#improvements-to-the-codebase)
- [Review Pull Requests](CONTRIBUTING.md#code-reviews)

# Troubleshooting

Please see our [troubleshooting guide](https://github.com/sendgrid/sendgrid-csharp/blob/master/TROUBLESHOOTING.md) for common library issues.
Please see our [troubleshooting guide](TROUBLESHOOTING.md) for common library issues.

# About

Expand Down
2 changes: 1 addition & 1 deletion TROUBLESHOOTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ In most cases we recommend you download the latest version of the library, but i
<a name="versioning"></a>
## Versioning Convention

We follow the MAJOR.MINOR.PATCH versioning scheme as described by [SemVer.org](http://semver.org). Therefore, we recommend that you always pin (or vendor) the particular version you are working with to your code and never auto-update to the latest version. Especially when there is a MAJOR point release, since that is guaranteed to be a breaking change. Changes are documented in the [CHANGELOG](https://github.com/sendgrid/sendgrid-csharp/blob/master/CHANGELOG.md) and [releases](https://github.com/sendgrid/sendgrid-csharp/releases) section.
We follow the MAJOR.MINOR.PATCH versioning scheme as described by [SemVer.org](http://semver.org). Therefore, we recommend that you always pin (or vendor) the particular version you are working with to your code and never auto-update to the latest version. Especially when there is a MAJOR point release, since that is guaranteed to be a breaking change. Changes are documented in the [CHANGELOG](CHANGELOG.md) and [releases](https://github.com/sendgrid/sendgrid-csharp/releases) section.

<a name="request-body"></a>
## Viewing the Request Body
Expand Down
2 changes: 1 addition & 1 deletion USAGE.md
Original file line number Diff line number Diff line change
Expand Up @@ -2450,7 +2450,7 @@ For more detailed information about how to use the v3 Mail Send endpoint, please

### POST /mail/send

This endpoint has a helper, check it out [here](https://github.com/sendgrid/sendgrid-csharp/blob/master/src/SendGrid/Helpers/Mail).
This endpoint has a helper, check it out [here](src/SendGrid/Helpers/Mail).

```csharp
string data = @"{
Expand Down
12 changes: 6 additions & 6 deletions USE_CASES.md
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ namespace Example
};
msg.AddHeaders(headers);

// If you require complex substitutions this [use case](https://github.com/sendgrid/sendgrid-csharp/blob/master/USE_CASES.md#transactional-templates).
// If you require complex substitutions this [use case](USE_CASES.md#transactional-templates).
var dynamicTemplateData = new ExampleTemplateData
{
Subject = "Hi!",
Expand Down Expand Up @@ -201,7 +201,7 @@ namespace Example
};
msg.AddHeaders(headers1, 1);

// For a full transactional template example, please see this [use case](https://github.com/sendgrid/sendgrid-csharp/blob/master/USE_CASES.md#transactional-templates).
// For a full transactional template example, please see this [use case](USE_CASES.md#transactional-templates).
var dynamicTemplateData2 = new ExampleTemplateData
{
Subject = "Hi 2!",
Expand Down Expand Up @@ -244,7 +244,7 @@ namespace Example
msg.AddContents(contents);

// For base64 encoding, see [`Convert.ToBase64String`](https://msdn.microsoft.com/en-us/library/system.convert.tobase64string(v=vs.110).aspx)
// For an example using an attachment, please see this [use case](https://github.com/sendgrid/sendgrid-csharp/blob/master/USE_CASES.md#attachments).
// For an example using an attachment, please see this [use case](USE_CASES.md#attachments).
msg.AddAttachment("balance_001.pdf",
"base64 encoded string",
"application/pdf",
Expand All @@ -271,7 +271,7 @@ namespace Example
};
msg.AddAttachments(attachments);

// For a full transactional template example, please see this [use case](https://github.com/sendgrid/sendgrid-csharp/blob/master/USE_CASES.md#transactional-templates).
// For a full transactional template example, please see this [use case](USE_CASES.md#transactional-templates).
msg.SetTemplateId("d-d42b0eea09964d1ab957c18986c01828");

msg.AddGlobalHeader("X-Day", "Monday");
Expand Down Expand Up @@ -858,14 +858,14 @@ var client = new SendGridClient(options);
<a name="domain-authentication"></a>
# How to Setup a Domain Authentication

You can find documentation for how to setup a domain authentication via the UI [here](https://sendgrid.com/docs/ui/account-and-settings/how-to-set-up-domain-authentication/) and via API [here](https://github.com/sendgrid/sendgrid-nodejs/blob/master/packages/client/USAGE.md#sender-authentication).
You can find documentation for how to setup a domain authentication via the UI [here](https://sendgrid.com/docs/ui/account-and-settings/how-to-set-up-domain-authentication/) and via API [here](USAGE.md#sender-authentication).

Find more information about all of SendGrid's authentication related documentation [here](https://sendgrid.com/docs/ui/account-and-settings/).

<a name="email-stats"></a>
# How to View Email Statistics

You can find documentation for how to view your email statistics via the UI [here](https://app.sendgrid.com/statistics) and via API [here](https://github.com/sendgrid/sendgrid-csharp/blob/master/USAGE.md#stats).
You can find documentation for how to view your email statistics via the UI [here](https://app.sendgrid.com/statistics) and via API [here](USAGE.md#stats).

Alternatively, we can post events to a URL of your choice via our [Event Webhook](https://sendgrid.com/docs/API_Reference/Webhooks/event.html) about events that occur as Twilio SendGrid processes your email.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@

<h1>You have successfully launched the server!</h1>
<p>
Check out <a href="https://github.com/sendgrid/sendgrid-csharp/tree/master/examples/eventwebhook/consumer">the documentation</a> on how to use this webhook to utilize the SendGrid Event webhook.
Check out <a href="https://github.com/sendgrid/sendgrid-csharp/tree/HEAD/examples/eventwebhook/consumer">the documentation</a> on how to use this webhook to utilize the SendGrid Event webhook.
</p>
2 changes: 1 addition & 1 deletion examples/mail/mail.cs
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
////////////////////////////////////////////////////////
// v3 Mail Send
// POST /mail/send
// This endpoint has a helper, check it out [here](https://github.com/sendgrid/sendgrid-csharp/blob/master/src/SendGrid/Helpers/Mail/README.md).
// This endpoint has a helper, check it out [here](https://github.com/sendgrid/sendgrid-csharp/blob/HEAD/src/SendGrid/Helpers/Mail/README.md).

string data = @"{
'asm': {
Expand Down
4 changes: 2 additions & 2 deletions src/SendGrid/Helpers/Mail/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@

# Quick Start

Run the [Example Project](https://github.com/sendgrid/sendgrid-csharp/tree/master/ExampleCoreProject) (make sure you have set your Environment variable to include your SENDGRID_API_KEY).
Run the [Example Project](../../../../ExampleCoreProject) (make sure you have set your Environment variable to include your SENDGRID_API_KEY).

Click on the Example project, then click the `Start` button in the menu.

## Usage

- See the [example](https://github.com/sendgrid/sendgrid-csharp/tree/master/ExampleCoreProject/Example.cs) for a complete working example.
- See the [example](../../../../ExampleCoreProject/Program.cs) for a complete working example.
- [Documentation](https://sendgrid.com/docs/API_Reference/Web_API_v3/Mail/index.html)
Binary file added twilio_sendgrid_logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 7b399a0

Please sign in to comment.