Skip to main content

Questions tagged [api]

An application programming interface (API) specifies how some software components should interact with each other. In addition to accessing databases or computer hardware, such as hard disk drives or video cards, an API can be used to ease the work of programming graphical user interface components. In practice, most often an API is a library that includes specifications for routines, data structures, object classes, and variables.

Filter by
Sorted by
Tagged with
0 votes
1 answer
27 views

Wordpress - Contact Form 7 - Get uploaded file issue

I'm aiming to submit my Contact Form 7 data in Wordpress to an API (all fields are fine, but adding the file attachment breaks my submit - error 500), which includes an attachment. I can make it work ...
Pbalazs89's user avatar
  • 115
1 vote
0 answers
45 views

How to use WordPress REST API to login a user with dart/flutter?

I'm creating an app that will work on phones, tablets and computers. I need to be able to authenticate a user, reset a password, retrieve their name and email, all via the WP API. I have zero clue how ...
Erin Skidds's user avatar
0 votes
0 answers
31 views

Can't make an external api call in php side of wordpress child theme

Edited 07-14-24 to show permission callback in api Edit 2: showed my fatal error I'm new to making api calls in wordpress. I need to make an api call through the backend to a 3rd party api. I can't do ...
vroque2022's user avatar
0 votes
0 answers
16 views

Trouble Fetching Posts Using WordPress API: No Response from Specific Category

I'm facing difficulties while retrieving posts via the WordPress API, specifically when attempting to fetch posts from a particular category. Here's the issue in detail: Fetching Posts by Category: ...
Leead's user avatar
  • 1
1 vote
0 answers
16 views

Wordpress Custom API GET request from External App with XML Parameter

I am new to WordPress API's and API's in general. I have an external app that is sending a GET request to my WordPress site with an XML string as the only parameter. I created a custom API that ...
Eugene's user avatar
  • 11
1 vote
1 answer
32 views

how to send csv file to other server using wp_remote_post?

I am facing issue while sending csv file to api. when i use simple php curl request it works fine for me and it sends the file to server. here is my php code $curl = curl_init(); curl_setopt_array( $...
wp_dev's user avatar
  • 11
0 votes
1 answer
31 views

How to get a list of all posts and their categories?

Basically I just need to have a table like this: Post title Categories Post 1 Category 1, Category 2 Post 2 Category 2, Category 2.1 ... ... From MySQL Query to Retrieve Category from wp_posts I ...
Ooker's user avatar
  • 332
0 votes
0 answers
20 views

Display a list on the front end from wp_remote_get()

I am getting the data I need from the request but I am not getting to the bottom of how to loop over the data and create a list on the front end. I presumed it would be a foreach loop but I am just ...
Craig Watson's user avatar
0 votes
0 answers
24 views

Trying to use value in form submission to check against external API

I'm trying to be as concise as possible. I'm building a form that takes a value ('address') which in turn would get posted to an external API. However, the real functionality comes with checking the '...
Cynthia Wong's user avatar
1 vote
0 answers
40 views

API to programmatically determine which wordpress plugins are out of date

Is there an API or an automated way to determine which plugins are out of date and/or have newer versions? I have about 10 different linux servers, and each server has at least 5 installations of ...
learningtech's user avatar
0 votes
0 answers
7 views

API call from searchbar in wordpress

I am adding a feature to my website where visitor enters keyword (dynamic), clicks submit in searchbar and an external API gets called. API responds with certain data which is then displayed on page. ...
Pratyush Tapaswi's user avatar
0 votes
0 answers
20 views

wordpress-plugin (widget) that performs a Neaby-search on the openstreetmap-endpoint: around x find y

i am about to create a wordpress-plugin that offers the output of the following data ... the data of a a Neaby-search: can we create a quewry that shows up all the schools that are in the near - in ...
zero's user avatar
  • 170
1 vote
1 answer
35 views

Wordpress Rest API Post request from AMP

I am trying to figure out how to send a post request to a WP Rest API function on an AMP Page. The endpoint requires 2 fields, post_id & nonce. /wp-json/wordpress-popular-posts/v2/views/[post_id] ...
GoSSDHosting's user avatar
0 votes
0 answers
57 views

REST API Plugin Update call back not updating the plugin

I am working on a custom CRM which includes keeping an eye on my clients WordPress sites so I have created some custom REST API endpoints to collect different types of data like the installed plugins &...
Eoin H's user avatar
  • 131
1 vote
2 answers
86 views

Post current post type to my Ajax

I have two files, alpine js and a ajax, i want to get my current post type from wordpress with $post_type = get_post_type( $post->ID ); $postType = get_queried_object(); $args = array( '...
Beep's user avatar
  • 29
0 votes
2 answers
76 views

Server 500 error when updating post using block editor

My client's website has a single post that when updated/saved using the block editor displays the following in the browser console: XHR Post Status 500 https://www.wanderwoman.ca/wp-json/wp/v2/posts/...
Mike Hermary's user avatar
0 votes
0 answers
25 views

Display endpoint's return into a file (file_put_contents())

I've created a form (using WS FORM RUN WORDPRESS HOOK) than when submitted triggers a php script that grabs all the submitted data written on the fields and save them into $variables and everything ...
WinterCold's user avatar
0 votes
0 answers
55 views

Looking for a working code example in python for creating a post

There are numerous wrong, old, conflicting, and non-working examples for posting in WordPress using python. Every example I have seen has failed and error messages leave a lot of possible solutions. ...
disruptive's user avatar
0 votes
1 answer
43 views

Read data from external source. XML vs REST API

I have a WordPress site and I should read data from an external source to populate parts of the various pages. I can choose whether to have the external data in an xml or via rest api. The xml will ...
Stefano Vet's user avatar
0 votes
1 answer
55 views

Encountering 400 Bad Request Error When Sending Form Information to API through Elementor

I’m currently working with an API and Elementor, and I’m trying to send form information to the platform API. However, I’m encountering a 400 Bad Request error when making a request to my server. The ...
Diane Rendel's user avatar
0 votes
0 answers
125 views

Transmit headers and footers via API from one site to another

I'm trying to have the same header and footer as my WordPress site on another site (that doesn't use WordPress) with a different domain and hosting. The manager of the other site wants it via API but ...
LesCa's user avatar
  • 21
0 votes
0 answers
28 views

Can't save Image from external API into Database

I am trying to create a plugin that gets data from an external API and stores the data into the database. The data I am receiving, contains Texts and Images. I have to save them separately as in the ...
I. Antonov's user avatar
0 votes
1 answer
275 views

WordPress getting data from external API

I am trying to create a Plugin that does the following jobs: Authenticate the user to get Bearer token 'access_token' Get data from API and store in Database I have checked all the APIs and ...
I. Antonov's user avatar
0 votes
1 answer
39 views

Image size not showing up in 'wp/v2/media'

I'm trying to get the URL of a specific image size, and I'm using apiFetch: const response = await apiFetch({ path: `wp/v2/media/${id}`, method: "GET", }); The ...
Vincent's user avatar
0 votes
1 answer
325 views

'403 Forbidden' when publishing a post containing different blocks

I'm experiencing a werid issue I never ran into before. I'm on WordPress 6.3.1 and each time I try to publish a post on my blog I get the "Updating failed. The response is not a valid JSON ...
Css14's user avatar
  • 13
0 votes
1 answer
25 views

I only want to show links to categories that have posts in 'publish' state in my menu

I am working on a WordPress project where I want to dynamically filter menu items (and possibly their parent items) based on whether they are associated with any published posts. Specifically, I am ...
DiaJos's user avatar
  • 101
0 votes
0 answers
19 views

Can external API content be added to Rest API in Wordpress

Is it possible to fetch data from an external API, and put them inside of Wordpress REST API? For example, schema would look like this $api = 'https://valorant-api.com/v1/agents'; $json_data = ...
Jovan Jovanovic's user avatar
0 votes
0 answers
28 views

wp_remote_post to admin-ajax.php isn't sending body value

I'm trying to get my code to get the TMDB API data but since the API response contains multiple pages, I'm trying to recursive call my function and increment the page number each time. I'm logging to ...
SeanB's user avatar
  • 1
0 votes
1 answer
66 views

Trying to create and update wordpress from python library

The Background: I am a software developer that is trying to create a sports analytics website. I used to created wordpress-based sites on the side so I have a WHM where I can host sites. I'd prefer ...
AdamCodes716's user avatar
0 votes
1 answer
337 views

Appointment booking system in WordPress

I have to make an appointment booking system with WordPress, I have a custom post type "appointments" with various various custom fields like : Name, email, date, time, office, service... ...
LesCa's user avatar
  • 21
2 votes
1 answer
814 views

Can I send a body using wp_remote_get()?

I'm writing a WordPress plugin and want to retrieve data from my API on another domain using wp_remote_get() On this page: https://wp-kama.com/function/wp_remote_get There is a Usage Template: $...
HardlyNoticeable's user avatar
0 votes
0 answers
153 views

How to pass a file to an API call through WordPress

I want to pass a file to an API call for translation the action of this button of submit still doesn't direct to any page, so should I make this pure PHP or Ajax gonna take a role here? This's the ...
Mostafa Ezzat's user avatar
0 votes
1 answer
283 views

All wp-json routes suddenly return 404

I'm having a problem, where all API routes on a site are now returning a 404 error. This has been working for quite some time but just recently started doing this. I'm not sure if it was from an ...
chrispytoes's user avatar
0 votes
1 answer
34 views

How to submit a button automatically after every scheduled hours?

How to submit a button automatically after every scheduled hours ? I tried some JavaScript but all failed. What I am doing? I am trying to fetch product categories from an external API Why I want ...
Ricky's user avatar
  • 53
0 votes
0 answers
184 views

How to consume external API from WordPress post editor and display the response data in the custom field?

I am developing a custom post type called "Team," where I will add some profiles of team members. I am using ACF for the custom field to add personal details of the members (I can also ...
Rousnay's user avatar
0 votes
1 answer
516 views

Uploading media to wordpress API with C# HttpClient

I was trying to save some media but I can't get it to work. I don't know if its the authorization is the wrong format, or if its the content is just put in wrong. If someone knows how to please help ...
UltimateSeeSharp's user avatar
1 vote
1 answer
447 views

JS WordPress API fetch no response headers

I am using the @wordpress/api-fetch package to try and retrieve the information for a Custom Post Type like so: const query = { page: currentPage, parse: false, per_page: 1, status: 'publish', }; ...
Ronald's user avatar
  • 43
0 votes
0 answers
225 views

Issue with API after 6.2 update

I have a python program that automatically updates pages/posts on my websites. Recently I started getting this error only on the websites with 6.2 update: 400 - Bad Request | Your browser sent a ...
Fadi's user avatar
  • 73
0 votes
1 answer
69 views

Forminator + Hubspot Workflows

I need to send Forminator form data to a Hubspot workflow for a client. This doesn't seem to be working function send_form_data_to_hubspot($form_data) { $hubspot_api_key = 'MY_API_KEY'; $...
Mark Tabner's user avatar
0 votes
1 answer
193 views

Adding Microsoft Teams Incoming Webhook to WordPress, Problem with Rest Route?

I am trying to implement an incoming webhook on my WordPress website to send a message to MS Teams when I receive a form submission. The message includes an ActionCard with a multiple choice input ...
Aristocles's user avatar
0 votes
1 answer
471 views

Login and register by API

When we install WordPress with Softaculous, a Login button appears and we log in to the site without entering the username and password we pressed. We have a site where we sell digital subscriptions. ...
sakarya's user avatar
  • 222
0 votes
1 answer
91 views

Using Wordpress API to mass update posts freezes the server

Our site has recently been infected and a malware code was added to all the 5300+ posts. I wrote a simple app using Wordpress PCL to update the texts of all posts. But after updating a couple hundreds ...
unnanego's user avatar
0 votes
0 answers
165 views

Unable to retrieve Users (Not logged in) through WP Rest API

We are able to retrieve Rest API results of our WP database, running a Learndash plugin. We can retrieve details while not logged into the WP site, although limited (10 records or so). While logged in ...
Matthew Wragg's user avatar
0 votes
2 answers
552 views

Programmatically creating posts based on external JSON feed (asynchronously)

I am currently trying to create a Wordpress plugin which create posts in the Wordpress database based on data from an external JSON API. As an example this NewsAPI feed could be used: https://newsapi....
Joachim's user avatar
  • 21
0 votes
2 answers
753 views

External api call using wordpress

I want to start a new website and chose wordpress as my cmd, but im having a restriction. The website is all about api request to other websites and i triedto get an api to test it as an example. ...
Taofeeq Tajudeen 's user avatar
2 votes
1 answer
945 views

Is it possible to create post in wordpress using postman?

We have tried to create a post in WordPress using postman, can't able to create one since we have received an error as you are not allowed to do this action Even though I entered the admin login, it ...
Ajith kumar's user avatar
0 votes
1 answer
24 views

How to write a plugin that "listens" every time, an edit occurs?

Let's say I want to write a plugin that replaces (i.e.: overwrites) every src-tag of every iframe-element on a WP-Website with a custom string AND the plugin shall watch every new post or page-edit ...
mdthh's user avatar
  • 103
0 votes
0 answers
95 views

move setting data from wordpress api to codestar freamwork

I am coding a plugin that uses the Star code framework It should be mentioned that I had written this plugin using WordPress API before. Now I want to integrate and make it more advanced, but I ran ...
masoud nkh's user avatar
0 votes
0 answers
31 views

display posts, pages and custom post types from another wordpress site

I have 2 sites one acting as a parent and the second acting as a branch of the organization. The sites are on different domains and databases. I want to display on the branch site some posts and ...
Joxmar's user avatar
  • 103
1 vote
1 answer
62 views

Store large dataset in WordPress installation temporary

My WordPress plugin depends on a large dataset (around a megabyte). The dataset is downloaded through REST API and then decoded to a PHP array. Right now the dataset is downloaded on each page load ...
pstidsen's user avatar

1
2 3 4 5
16