Skip to content

Instantly share code, notes, and snippets.

@devxpy
Created December 24, 2024 04:19
Show Gist options
  • Save devxpy/0309ef27a2ca852966e9f45ae1e9ec69 to your computer and use it in GitHub Desktop.
Save devxpy/0309ef27a2ca852966e9f45ae1e9ec69 to your computer and use it in GitHub Desktop.
Gooey.AI Lipsync Flutter Wav2Lip
import 'package:http/http.dart' as http;
import 'dart:convert';
main() async {
var request = http.MultipartRequest(
'POST',
Uri.parse('https://api.gooey.ai/v3/Lipsync/async/form/'),
);
request.headers['Authorization'] = 'bearer sk-hhm...POJ';
request.files.add(http.MultipartFile.fromBytes('input_face', []));
request.files.add(http.MultipartFile.fromBytes('input_audio', []));
request.fields['json'] = jsonEncode({
"face_padding_top": '0',
"face_padding_bottom": '0',
"face_padding_left": '0',
"face_padding_right": '0',
"selected_model": "Wav2Lip",
});
var response = await request.send();
print(response.statusCode);
print(await response.stream.bytesToString());
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment