Make WordPress Core

Opened 8 years ago

Closed 8 years ago

Last modified 8 years ago

#36197 closed defect (bug) (fixed)

Update Twitter oEmbed URL

Reported by: niallkennedy's profile niallkennedy Owned by: ocean90's profile ocean90
Milestone: 4.5 Priority: normal
Severity: normal Version:
Component: Embeds Keywords: has-patch
Focuses: Cc:


Twitter moved its preferred oEmbed URL for single Tweets from to

Update the oEmbed provider array to point at the new preferred endpoint, matching autodiscovery behavior. The XML response format will be removed.

Example URL:

Attachments (3)

36197.diff (1.3 KB) - added by niallkennedy 8 years ago.
36197.2.diff (1.4 KB) - added by ocean90 8 years ago.
36197.3.diff (1.6 KB) - added by ocean90 8 years ago.

Download all attachments as: .zip

Change History (14)

8 years ago

#1 @niallkennedy
8 years ago

  • Keywords has-patch added

#2 @jorbin
8 years ago

  • Milestone changed from Awaiting Review to 4.5
  • Type changed from enhancement to defect (bug)

As twitter is deprecating the XML on May 1, I think this is a good fix to get in for 4.5

8 years ago

#3 @ocean90
8 years ago

  • Version trunk deleted

36197.2.diff adds support for moments, which are supported by the new endpoint, see

#4 @jorbin
8 years ago

  • Owner set to jorbin
  • Resolution set to fixed
  • Status changed from new to closed

In 36946:

Update Twitter oEmbed URL.

Twitter moved its preferred oEmbed URL for single Tweets from to They also are deprecating XML responses.

Props niallkennedy.
Fixes #36197.

#5 @jorbin
8 years ago

  • Resolution fixed deleted
  • Status changed from closed to reopened

#6 @jorbin
8 years ago

  • Owner changed from jorbin to ocean90
  • Status changed from reopened to assigned

@ocean90 Do you want to add the moments support? Is that not covered by the current autodiscovery?

#7 @ocean90
8 years ago

@jorbin Autodiscovery works only if the page includes the link tag, has none. A single tweet like includes one though.

@niallkennedy Is this something which Twitter is planning to implement?

#8 @niallkennedy
8 years ago

We will return an oEmbed response from the same API URL for Moment and collection URLs today. We plan to add autodiscovery.

#9 @ocean90
8 years ago

Thanks @niallkennedy, I'm going to add support for the new URLs.

Autodiscovery doesn't work for these because wp_filter_oembed_result() filters the HTML data.

Last edited 8 years ago by ocean90 (previous) (diff)

8 years ago

#10 @ocean90
8 years ago

  • Resolution set to fixed
  • Status changed from assigned to closed

In 36954:

oEmbed: Extend the provider list to support moments and timelines from Twitter.

Fixes #36197.

#11 @DrewAPicture
8 years ago

In 37038:

Docs: Add Twitter timelines and moments to the table in the hook doc for the oembed_provders filter, introduced in [36954].

See #36197. See #35986.

Note: See TracTickets for help on using tickets.